Commit Graph

52 Commits

Author SHA1 Message Date
R. Tyler Croy 48d3f248ba Merge pull request #33 from rtyler/five-zero-fixes
Better integration testing and a bug fix
2015-09-21 16:31:44 -07:00
R. Tyler Croy 6506a3d5d4
If no parentTask for JRubyStormLocal is set, use the default configuration for the classpath
Fixes #29
2015-09-21 15:59:39 -07:00
R. Tyler Croy 2a3f0b709a
Start adding more integration test cases including one for JRubyStormLocal tasks 2015-09-21 14:48:17 -07:00
R. Tyler Croy 2ad81ecb40
Upgrade the gradle wrapper
Bumping to Gradle 2.7
2015-09-21 14:48:01 -07:00
R. Tyler Croy 2becff34d2
Propogate task dependencies from JRubyStorm to its children tasks
Fixes #31
2015-09-20 17:48:18 -07:00
R. Tyler Croy 7b1c81004c
Upgrade to the latest stable redstorm (0.9.2)
Fixes #27
2015-09-15 14:38:01 -07:00
R. Tyler Croy 94d7efc522
Avoid trying to normalize paths for the JRubyStormLocal configuration
This can cause problems, apparently, on Mac OS X such as:

    > Could not normalize path for file '/Users/asavchenko/.gradle/caches/modules-

NOTE: This has not yet been tested on OS X
2015-09-15 14:28:37 -07:00
R. Tyler Croy 790772a8f7
Upgrade the default redstorm version 2015-09-11 11:19:36 -07:00
R. Tyler Croy 16a7f0886b
Work-around Gradle 2.2 super() issue by not calling super at all
According to @ysb33r:

    Gradle 2.2 is indeed the culprit. There was binary change in the Jar class when
    they moved it from a Groovy implementation to a Java one. It was corrected in a
    subequent release, but 2.2 remains an issue.

Gradle 2.2 was just a bad release :(

Fixes #26
2015-09-11 08:55:30 -07:00
R. Tyler Croy 27ec0761d0
Upgrade to jruby/gradle core 1.0.4 with some more recent bugfixes
This commit also changes JRubyStormJar a bit to override properties now that
they are properly overwritable in 1.0.4

Fixes #22
2015-09-10 16:03:57 -07:00
R. Tyler Croy b8f6b9886e
Set some default groups and descriptions on our packaging/run tasks
Fixes #19
2015-09-10 11:20:44 -07:00
R. Tyler Croy ca083054b4
Ensure that setting of the jrubyVersion for the topology jar works properly
This contains some workarounds until jruby-gradle/redstorm#11 is fixed which
will allow us to work on JRuby 9k, until then we'll default to the latest
stable JRuby 1.7.x branch

Fixes #23
2015-09-09 15:33:56 -07:00
R. Tyler Croy a6d92230c9
Ensure that the jrubyStormLocal configuration extends the classpath configuration 2015-09-09 15:33:40 -07:00
R. Tyler Croy 26a8316f49
Introduce a new configuration for unzipping things directly into the topology jar
This goes hand-in-hand with jruby-gradle/redstorm#12 and allows us to
incorporate things like storm-kafka early on in the load time of a topology
while still allowing most JRuby-originating jar dependencies to be packed "as
per usual." (See fast-rsa-engine and others which pack jar files inside gem
archives)

Fixes #25
2015-09-09 13:51:42 -07:00
R. Tyler Croy 61794ed1d2
Upgrade to the latest version of JRuby 1.7.x 2015-09-09 13:06:12 -07:00
R. Tyler Croy d60010f797
Rely on the user to provide a jcenter-compatible repository by default
Fixes #18
2015-09-09 13:06:12 -07:00
R. Tyler Croy a0b287c92a
Prevent JRubyStormLocal task from erroneously using the jrubyExec configuration
Fixes #12
2015-08-18 10:52:58 -07:00
R. Tyler Croy 90c92d045d
Fix null dereference when JRubyStormLocal is standalone, i.e. no parentTask
Fixes #11
2015-08-18 10:01:53 -07:00
R. Tyler Croy 8c7e2ddc14
Delegate to our assembleTask for methods not already defined in JRubyStorm
Fixes #13
2015-08-18 09:39:08 -07:00
R. Tyler Croy 2046c89c29
Executing the jrubyStorm task should also execute its assemble task
Fixes #14
2015-08-17 16:10:00 -07:00
R. Tyler Croy 2934164708
Upgrade to the latest release of redstorm which has some better version ranges 2015-08-17 16:09:37 -07:00
R. Tyler Croy dec7a74629
Mark the storm extension as incubating for now
Given the troubles with jruby.defaultVersion in the code plugins, I'm not sure
this is a great pattern
2015-08-16 12:44:55 -07:00
R. Tyler Croy 85fea21820
Lazily include the redstorm jar to avoid compatibiity issues on Gradle 2.2
There's an issue with overriding copy() in Gradle 2.0 -> Gradle 2.2
    <https://issues.gradle.org/browse/GRADLE-3207>

    Caused by: groovy.lang.MissingMethodException: No signature of method: com.github.jrubygradle.storm.internal.JRubyStormJar_Decorated.copy() is applicable for argument types: () values: []
    Possible solutions: copy(), any(), any(groovy.lang.Closure), notify(), wait(), find()
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:55)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:130)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:148)
        at com.github.jrubygradle.storm.internal.JRubyStormJar.copy(JRubyStormJar.groovy:43)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:63)
2015-08-14 18:53:51 -07:00
R. Tyler Croy add7020757
Default to using redstorm 0.7.2 2015-08-14 17:07:42 -07:00
R. Tyler Croy 6f0bd71f12
Default to JRuby 1.7.21 for packaging up topology jars 2015-08-14 17:06:53 -07:00
R. Tyler Croy 363821f23b
Dump the redstorm contents into the resulting archive 2015-08-14 16:23:04 -07:00
R. Tyler Croy d7288e23a9
Properly packaging up the topology code inside of the jar
Fixes #6
2015-08-14 15:00:33 -07:00
R. Tyler Croy 8c3ea3fd26
Attempting to clean up these loglevels on ProjectBuilder but they just won't set
Need to work with somebody in the Gradle community to figure out why these
Project fixtures won't use anything other than DEBUG level logging
2015-08-14 12:27:38 -07:00
R. Tyler Croy 4d340fc42c
Shuffle some tests around so they don't run in the integrationTest task 2015-08-14 11:47:26 -07:00
R. Tyler Croy fe5a55d754
Introduce some GradleTestKit-based tests and the supporting infra to run them
Some of this was unapologetically pilfered from the core plugins
2015-08-14 11:24:32 -07:00
R. Tyler Croy 988888d068
Move integration tests into a separate task and start using GradleTestKit
This commit introduces a failing integration test, that's expected
2015-08-11 08:27:25 -07:00
R. Tyler Croy 4d1dc25e59
Make the word-count example a gradleTest while we're at it 2015-08-10 09:31:27 -07:00
R. Tyler Croy 352d44b34b
Properly make use of JRubyExecTraits API to run our environment and prepare dependencies
Fixes #4
Fixes #7
2015-07-30 07:35:14 -07:00
R. Tyler Croy 3f39e00e95
WIP checkpointing some refactoring and structuring around the JRubyStorm task 2015-07-28 05:19:21 -07:00
R. Tyler Croy cc4b707d1d
Start relocating basic topology jar functionality into JRubyStorm class
This will make it easier to move over to JRubyJar soon

References #6, #8
2015-07-27 08:01:21 -07:00
R. Tyler Croy d0cf8246a6
Move JRubyStormLocal to inherit from JRubyExec
This means that we will have the same dependency management behavior and
classpaths as we have in JRubyExec, which should fix up #7

Fixes #7
2015-07-27 07:59:17 -07:00
R. Tyler Croy 611a52820f
Support modifying the version of redstorm included as well
References #3
2015-07-27 00:03:50 -07:00
R. Tyler Croy 6aa1174faf
Add an extension to the Gradle project which allows for configuring the Storm version
Since this is only used for running local topologies, we're just adding it to
the jrubyStormLocal configuration

Fixes #3
2015-07-26 23:50:31 -07:00
R. Tyler Croy 072210343f
Introduce codenarc to keep this groovy tidy 2015-07-26 22:41:25 -07:00
R. Tyler Croy 28756c36c4
Disable the creation of a JRuby-specific jar and remove the BC dependency
The BC version being included was an artifact from using older versions of
jruby-complete (pre 1.7.20), see 5d59833e998ceed24e0805e09d36897de770838f

The fact that this doesn't fail any tests is a problem :)
2015-07-26 22:31:55 -07:00
R. Tyler Croy 66e6764c59
Introduce the gradleTest plugin (yet unused) for testing on different Gradles 2015-07-26 22:19:14 -07:00
R. Tyler Croy 7028b6cc8f Revert "Remove bolts/ from the default topology jar"
Turns out this is kind of useful, whoops

This reverts commit fce4bb3488.
2014-11-17 20:10:02 -08:00
R. Tyler Croy fce4bb3488 Remove bolts/ from the default topology jar 2014-11-15 08:46:19 -08:00
R. Tyler Croy 72911dd80a Ensure the bouncycastle dependency is included in storm topologies so JRuby can run effectively 2014-11-15 08:45:13 -08:00
R. Tyler Croy f15caeca6f Upgrade the jrubyStormLocal dependency on storm-core 0.9.2-incubating by default
0.9.2 includes many fixes/improvements and is API incompatible with 0.9.1. The
only requirement that we have for 0.9.1 anymore is on storm topology
deployment, everywhere else we should rely on 0.9.2 if possible

This resolves some frustrating issues with incompatibilities with zookeeper and
curator dependencies underneath storm-kafka 0.9.2-incubating. If you've seen
"cannot initialize class `backtype.storm.LocalCluster` then that means that ZK
dependencies are somehow incorrect in the classpath causing the LocalCluster
class, which is defined in Clojure, to fail to get created. Cute error
2014-11-04 06:08:09 -08:00
R. Tyler Croy 5d173bfd6d asPath isn't necessary and can cause problems with path lengths on OS X
See <https://gist.github.com/rtyler/e026eb127c36be9cd180>
2014-10-22 15:28:01 -07:00
R. Tyler Croy ddb39f0019 JRubyStormLocal should depend on the jrubyPrepare task to set up gems 2014-10-22 15:26:10 -07:00
R. Tyler Croy 29c85e7091 Set the right GEM_HOME/GEM_PATH for loading gems in the local topology
Fixes #1
2014-10-22 14:42:45 -07:00
R. Tyler Croy 8cd3e8ce66 Rely on shadowJar for unzipping dependencies into the jar instead of doing it manually 2014-10-22 14:01:53 -07:00
R. Tyler Croy ece8b5f9eb Exclude jar signing keys when we're creating the shadow jar 2014-10-22 13:19:31 -07:00