Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run all branches against JRuby on CI #1496

Merged
merged 1 commit into from
Mar 8, 2016
Merged

Run all branches against JRuby on CI #1496

merged 1 commit into from
Mar 8, 2016

Conversation

nadavshatz
Copy link
Contributor

Meant to resolve #1409

  • Added recent JRuby versions to .travis.yml
  • Added OracleJDK8 and OracleJDK7 (Travis default) builds
  • Added Changelod line under misc

@bf4
Copy link
Member

bf4 commented Feb 5, 2016

@nadavshatz Nice! 👍 do you think all these runs are worth the cost to the CI provider and time of the run? I've never tested against so many JDK's or point releases of JRuby.

@@ -9,6 +9,13 @@ rvm:
- 2.3.0
- ruby-head
- rbx-2
- jruby-9.0.4.0
- jruby-9.0.5.0
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are they different enough that it's worth having both?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One jruby-9xxx should be enough IMO. About having jruby-9xxx and jruby-head, I think it's generally a good idea to keep both. On the other side, I wonder if keeping 2.0.0 is necessary.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could also maybe consider using an include so that we don't run jrubies against all rails version.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@groyoh
jruby-9xxx and jruby-91xx (coming soon) are two different ruby versions. but for now, having just one jruby-9xxx should be enough, i agree.

regarding the include - you mean that we won't run jruby against Rails 4.0 ?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, Rails doesn't ;) rails/rails#23499

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, diff will be something like

   - 2.3.0
   - ruby-head
   - rbx-2
+  - jruby-9.0.5.0
+
+jdk:
+  - oraclejdk8
+
+before_install:
+  - '[ "$JRUBY_OPTS" != "" ] && export JRUBY_OPTS="-Xcompat.version=2.0 --server -Xcompile.invokedynamic=false -Xcli.debug=true --debug" && echo "JRUBY_OPTS: \'$JRUBY_OPTS\'"'

 install: bundle install --path=vendor/bundle --retry=3 --jobs=3
 cache:
@@ -30,10 +40,12 @@ matrix:
     env: RAILS_VERSION=master
   - rvm: 2.1
     env: RAILS_VERSION=master
   - rvm: jruby-head
-    env: JRUBY_OPTS='-Xcompat.version=2.0 --server -Xcompile.invokedynamic=false -Xcli.debug=true --debug'
+    env: RAILS_VERSION=5.0.0.beta2
   allow_failures:
     - rvm: ruby-head
+    - rvm: jruby-head
     - rvm: rbx-2
+   exclude:
+     - rvm: jruby-9.0.5.0
+       env: RAILS_VERSION=4.0
   fast_finish: true

@bf4
Copy link
Member

bf4 commented Feb 5, 2016

It also seems the Rails 4.0 is missing from the jruby 9k series... (only run on jruby-head). This is a version that often fails differently, so...

@nadavshatz
Copy link
Contributor Author

@bf4 First off thanks for the quick response!

Regarding the many JDK:
We use OracleJDK8, Travis has for default 7, which i think some ubuntu versions do as well, which means many people will use. I can change it to only use the latest (8) if you prefer.

Re many point releases:
I was only going to use the latest stable release (9.0.5.0) but we already encountered regression issues with it and I wanted the tests to represent at least 2 versions. Once Jruby 9.1.0.0 is release we can change it to that and the last 9.0... version.

Rails 4.0 was failing, I thought that considering it is so old there is no need to add it, but I can put it back if you'd like. should it not be allowed to fail? Also - Jruby 9.0.x.0 is ruby 2.2 compatible and I wasn't sure if that is the issue for Rails 4.0.

Let me know what you think and I'll update the PR!

@bf4
Copy link
Member

bf4 commented Feb 5, 2016

Well, we still support 4.0, so that needs to remain under test... I honestly don't know the value of testing the different jdks... I was going to ref Rails but it looks like they don't test JRuby at all anymore rails/rails@0e8c045

@nadavshatz
Copy link
Contributor Author

I removed OracleJDK7 and Added back Rails 4.0, is it possible that Rails 4.0 doesn't work with Ruby 2.2? I'm not sure why the tests are failing.

@nadavshatz
Copy link
Contributor Author

@bf4 I've updated the PR and i think its now how you wanted it ?

@nadavshatz
Copy link
Contributor Author

I'll pay attention and update to add/change to the latest stable versions as they come out with new PR's

env: RAILS_VERSION=4.0
- rvm: jruby-head
env: RAILS_VERSION=4.0
- rvm: jruby-9.0.5.0
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a duplicate from above at line 41.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, thanks!

@groyoh
Copy link
Member

groyoh commented Feb 28, 2016

This look good to me (apart the duplicate). @bf4 any objection?

@nadavshatz
Copy link
Contributor Author

@groyoh fixed the duplicate, thanks for that!

- oraclejdk8

before_install:
- '[ "$JRUBY_OPTS" != "" ] && export JRUBY_OPTS="-Xcompat.version=2.0 --server -Xcompile.invokedynamic=false -Xcli.debug=true --debug"'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plz change to 9.0.4.0 since travis caches it, faster, and JRUBY_OPTS to '--dev --debug --Xcli.debug=true'. see rails/rails#23499 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I pushed a fix for these, thanks!

Let me know if you want me to squash the commits into one.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Squash plz :)

On Mon, Mar 7, 2016 at 8:57 AM Nadav Shatz notifications@github.com wrote:

In .travis.yml
#1496 (comment)
:

@@ -9,6 +9,14 @@ rvm:

  • 2.3.0
  • ruby-head
  • rbx-2
      • jruby-9.0.5.0
      • jruby-head
    +jdk:
      • oraclejdk8
    +before_install:
      • '[ "$JRUBY_OPTS" != "" ] && export JRUBY_OPTS="-Xcompat.version=2.0 --server -Xcompile.invokedynamic=false -Xcli.debug=true --debug"'

I pushed a fix for these, thanks!

Let me know if you want me to squash the commits into one.


Reply to this email directly or view it on GitHub
https://github.com/rails-api/active_model_serializers/pull/1496/files#r55213932
.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nadavshatz you say done, but maybe you didn't push it yet?

@NullVoxPopuli
Copy link
Contributor

LGTM 👍 I'll merge if no one has objections.

@bf4
Copy link
Member

bf4 commented Mar 7, 2016

@NullVoxPopuli please wait for rebase

@NullVoxPopuli
Copy link
Contributor

I need to make a checklist for reviewing.

@nadavshatz
Copy link
Contributor Author

@bf4 @NullVoxPopuli Rebased and squashed. Commit should be clean now.

Please let me know if there is anything else missing/to be fixed.

Cheers 🍻

@NullVoxPopuli
Copy link
Contributor

cool, thanks, @nadavshatz -- just gotta wait for travis/appveyor

@@ -34,6 +34,7 @@ Misc:
- [#1535](https://github.com/rails-api/active_model_serializers/pull/1535) Move the adapter and adapter folder to
active_model_serializers folder and changes the module namespace. (@domitian @bf4)
- [#1497](https://github.com/rails-api/active_model_serializers/pull/1497) Add JRuby-9000 to appveyor.yml(@corainchicago)
- [#1496](https://github.com/rails-api/active_model_serializers/pull/1496) Run all branches against JRuby on CI
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nadavshatz would you mind adding this to the top of the list and give yourself credit? on CI (@nadavshatz). Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done! thanks!

NullVoxPopuli added a commit that referenced this pull request Mar 8, 2016
Run all branches against JRuby on CI
@NullVoxPopuli NullVoxPopuli merged commit b3c6c7e into rails-api:master Mar 8, 2016
@nadavshatz nadavshatz deleted the add-jruby-to-ci branch March 16, 2016 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Run all branches against JRuby on CI
4 participants