Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/1.1-stable' into merge-1.1-stable
Browse files Browse the repository at this point in the history
  • Loading branch information
headius committed Jun 4, 2024
2 parents faaabb6 + cbee8b5 commit 160e933
Show file tree
Hide file tree
Showing 49 changed files with 1,269 additions and 581 deletions.
158 changes: 152 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,18 @@ branches:
- /.*stable$/
- /^test-.*$/
rvm:
<<<<<<< HEAD
# NOTE: do not use jruby-19mode otherwise some specs might fail
# @see ruby/rack/application_spec.rb for an explanation on this
#- jruby-18mode
#- jruby-19mode
- jruby-1.7.16
- jruby-head
=======
- jruby-1.6.8
- jruby-1.7.26
#- jruby-9.1.8.0 see include matrix
>>>>>>> origin/1.1-stable
jdk:
- openjdk6
- oraclejdk7
Expand All @@ -27,20 +33,26 @@ gemfile:
- gemfiles/rails32.gemfile
- gemfiles/rails40.gemfile
- gemfiles/rails41.gemfile
env:
- JRUBY_OPTS="--1.8 $JRUBY_OPTS"
- JRUBY_OPTS="$JRUBY_OPTS" JAVA_OPTS="-Djruby.version=$JRUBY_VERSION" # for mvn's jruby plugins
- gemfiles/rails42.gemfile
#env:
##- JRUBY_OPTS="--1.8 $JRUBY_OPTS"
#- JRUBY_OPTS="$JRUBY_OPTS" JAVA_OPTS="-Djruby.version=$JRUBY_VERSION" # for mvn's jruby plugins
before_script:
<<<<<<< HEAD
- export JRUBY_OPTS="--server -Xcext.enabled=false -Xcompile.invokedynamic=false -J-XX:MaxPermSize=128m"
- export JRUBY_VERSION="1.7.13"
- jruby -S gem env || true
=======
- export JRUBY_OPTS="-Xcompile.invokedynamic=false -J-XX:MaxPermSize=96M"
>>>>>>> origin/1.1-stable
before_install:
# NOTE: RubyGems 2.4.x fails us at application_spec's gem_install_rack_unless_installed !
- (jruby --1.9 -S gem update --system 2.2.3) || true
- ((jruby -v | grep -v 9.[0-9].[0-9].[0-9]) && jruby --1.9 -S gem update --system 2.6.12) || true
- ((jruby -v | grep 1.8.7) && jruby --1.9 -S gem update --system 2.1.11) || true
- ((echo $BUNDLE_GEMFILE | grep rails23) && jruby --1.9 -S gem update --system 1.8.29) || true
matrix:
allow_failures:
<<<<<<< HEAD
#- gemfile: gemfiles/rails41.gemfile
exclude:
## avoid jruby-head with JDK6 :
Expand Down Expand Up @@ -125,15 +137,138 @@ matrix:
- rvm: jruby-1.7.16
gemfile: gemfiles/rails41.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
=======
- rvm: jruby-1.6.8
- gemfile: Gemfile
- gemfile: gemfiles/railsNG.gemfile
include:
# jruby-9.1.8.0
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails32.gemfile
jdk: oraclejdk7
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails32.gemfile
jdk: oraclejdk8
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails40.gemfile
jdk: oraclejdk7
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails40.gemfile
jdk: oraclejdk8
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails41.gemfile
jdk: oraclejdk7
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails41.gemfile
jdk: oraclejdk8
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails42.gemfile
jdk: oraclejdk7
- rvm: jruby-9.1.8.0
gemfile: gemfiles/rails42.gemfile
jdk: oraclejdk8
# rails NG
- rvm: jruby-9.1.8.0
gemfile: gemfiles/railsNG.gemfile
jdk: oraclejdk7
- rvm: jruby-9.1.8.0
gemfile: gemfiles/railsNG.gemfile
jdk: oraclejdk8
## rails 2.3 --1.8
- rvm: jruby-1.7.4
gemfile: gemfiles/rails23.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: oraclejdk7
- rvm: jruby-1.7.4
gemfile: gemfiles/rails23.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: oraclejdk8
## rails 3.1 --1.8
- rvm: jruby-1.7.4
gemfile: gemfiles/rails31.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: openjdk6
- rvm: jruby-1.7.4
gemfile: gemfiles/rails31.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: oraclejdk7
- rvm: jruby-1.7.26
gemfile: gemfiles/rails32.gemfile
env: JRUBY_OPTS="--2.0 $JRUBY_OPTS"
jdk: oraclejdk8
exclude:
# ## avoid jruby-9K with JDK6 :
# - rvm: jruby-9.1.8.0
# gemfile: Gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails23.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails30.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails31.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails32.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails40.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails41.gemfile
# jdk: openjdk6
# - rvm: jruby-9.1.8.0
# gemfile: gemfiles/rails42.gemfile
# jdk: openjdk6
## avoid jruby-1.6.8 with JDK8 :
- rvm: jruby-1.6.8
gemfile: Gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails23.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails30.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails31.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails32.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails40.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails41.gemfile
jdk: oraclejdk8
- rvm: jruby-1.6.8
gemfile: gemfiles/rails42.gemfile
jdk: oraclejdk8
## rails 4.0 won't run on JRuby 1.6
- rvm: jruby-1.6.8
gemfile: gemfiles/rails40.gemfile
jdk: openjdk6
- rvm: jruby-1.6.8
gemfile: gemfiles/rails40.gemfile
jdk: oraclejdk7
- rvm: jruby-1.6.8
gemfile: gemfiles/rails40.gemfile
jdk: oraclejdk8
## rails 4.1 won't run on JRuby 1.6
- rvm: jruby-1.6.8
gemfile: gemfiles/rails41.gemfile
>>>>>>> origin/1.1-stable
jdk: openjdk6
- rvm: jruby-1.7.16
gemfile: gemfiles/rails41.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: oraclejdk7
- rvm: jruby-1.7.16
gemfile: gemfiles/rails41.gemfile
env: JRUBY_OPTS="--1.8 $JRUBY_OPTS"
jdk: oraclejdk8
<<<<<<< HEAD
## rails 4.0 does not run on --1.8 (jruby-head)
#- rvm: jruby-head
# gemfile: gemfiles/rails40.gemfile
Expand Down Expand Up @@ -296,4 +431,15 @@ matrix:
- rvm: jruby-head
gemfile: gemfiles/rails31.gemfile
env: JRUBY_OPTS="$JRUBY_OPTS" JAVA_OPTS="-Djruby.version=$JRUBY_VERSION"
=======
## rails 4.2 won't run on JRuby 1.6
- rvm: jruby-1.6.8
gemfile: gemfiles/rails42.gemfile
jdk: openjdk6
- rvm: jruby-1.6.8
gemfile: gemfiles/rails42.gemfile
jdk: oraclejdk7
- rvm: jruby-1.6.8
gemfile: gemfiles/rails42.gemfile
>>>>>>> origin/1.1-stable
jdk: oraclejdk8
15 changes: 13 additions & 2 deletions Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ appraise "rails30" do
end

appraise "rails31" do
gem "i18n", "< 0.7"
gem "rails", "~> 3.1.12"
end

appraise "rails32" do
gem "i18n", "< 0.7"
gem "rails", "~> 3.2.21"
end

Expand All @@ -19,11 +21,20 @@ appraise "rails40" do
end

appraise "rails41" do
gem "rails", "~> 4.1.10"
gem "rails", "~> 4.1.16"
end

appraise "rails42" do
gem "rails", "~> 4.2.1"
gem "mime-types", "< 3", :require => false
gem "rails", "~> 4.2.9"
end

appraise "rails50" do
gem "rails", "~> 5.0.5"
end

appraise "rails51" do
gem "rails", "~> 5.1.2"
end

appraise "railsNG" do
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ GEM
rspec-support (3.13.1)

PLATFORMS
universal-java-1.8
universal-java-22

DEPENDENCIES
appraisal (< 1.0)
Expand Down
34 changes: 34 additions & 0 deletions History.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,37 @@
## 1.1.22

- compile using Java 6 source compat
- update (bundled) rack to 1.6.13
- avoid NativeException - not used on recent JRuby
- avoid Fixnum warning - assume recent JRuby
- Add error message to log when runtime error is handled (#213)

## 1.1.21 (17/09/17)

- update (bundled) rack to 1.6.8
- add Rack::Handler::Servlet::DefaultEnv#get_header (#212)
missing methods to handle ActionController::Base#reset_session
- can only safely stream natively on ActionDispatch <= 3.2 (#210)
(broken Rails streaming for Rails 4.x)
- when handling OPTION calls ignore both 'Date' and 'Allow' headers (#205)

## 1.1.20 (22/01/16)

- pre-maturely avoid Ruby frozen string literals coming at us ... ''.dup meh!
- allow to boot when RAILS_ROOT/public directory does not exist (closes #197)
- for better booter detection - export public path after working dir was changed
- `ActionController::Base` provides a method `servlet_response` to return the
`java.servlet_response` rack env (#201)
- adjust jruby home dir fallback (for default $LOAD_PATH) correctly on 9K and --2.0
- servlet env should behave on `fetch` and `[]` like a Hash (nil value can be set)

## 1.1.19 (01/07/15)

- update (bundled) rack to 1.5.5
- servlet attrs with null/false values should not end up with an '' env value (#195)
- tune ErrorApp + ShowStatus to respect set 'rack.showstatus.detail' (#194)
- allow for more `JRuby::Rack::ErrorApp` customizations + retrieve cause when needed

## 1.1.18 (13/01/15)

- back-port Rack::ShowStatus to be used with out ErrorApp (contains XSS fix #190)
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#--
# The MIT License
#
# Copyright (c) 2012-2014 Karol Bucek, LTD
# Copyright (c) 2012-2016 Karol Bucek, LTD.
# Copyright (c) 2010-2012 Engine Yard, Inc.
# Copyright (c) 2007-2009 Sun Microsystems, Inc.
#
Expand Down
15 changes: 10 additions & 5 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,16 @@ end
desc "Unpack the rack gem"
task :unpack_gem => "target" do |t|
target = File.expand_path(t.prerequisites.first)
spec = Gem.loaded_specs["rack"]
if spec.respond_to?(:cache_file)
gem_file = spec.cache_file
else
gem_file = File.join(spec.installation_path, 'cache', spec.file_name)
spec = Gem.loaded_specs['rack']
# JRuby <= 1.7.20 does not handle respond_to? with method_missing right
# ... issue with Bundler::StubSpecification wrapping (in bundler 1.10.x)
unless ( gem_file = spec.cache_file rescue nil )
#if defined?(::Bundler) && ::Bundler.const_defined?(:StubSpecification) # since Bundler 1.10.1
# spec = spec.to_spec if spec.is_a?(::Bundler::StubSpecification)
#else
# spec = spec.to_spec if spec.respond_to?(:to_spec)
#end
gem_file = File.join(spec.base_dir, 'cache', spec.file_name)
end
unless uptodate?("#{target}/vendor/rack.rb", [__FILE__, gem_file])
mkdir_p "target/vendor"
Expand Down
3 changes: 2 additions & 1 deletion gemfiles/rails23.gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

source "https://rubygems.org"

gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
gem "rspec", "~> 2.14.1", :group=>:test
gem "jruby-openssl", "~> 0.9.20", :group=>:test
gem "rails", "~> 2.3.18"

9 changes: 7 additions & 2 deletions gemfiles/rails23.gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ GEM
activesupport (= 2.3.18)
activesupport (2.3.18)
diff-lcs (1.2.5)
jruby-openssl (0.9.21-java)
rack (1.1.6)
rails (2.3.18)
actionmailer (= 2.3.18)
Expand All @@ -20,7 +21,7 @@ GEM
activeresource (= 2.3.18)
activesupport (= 2.3.18)
rake (>= 0.8.3)
rake (10.3.2)
rake (10.4.2)
rspec (2.14.1)
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
Expand All @@ -34,6 +35,10 @@ PLATFORMS
java

DEPENDENCIES
jruby-openssl (~> 0.9.20)
rails (~> 2.3.18)
rake (~> 10.3.1)
rake (~> 10.4.2)
rspec (~> 2.14.1)

BUNDLED WITH
1.14.6
3 changes: 2 additions & 1 deletion gemfiles/rails30.gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

source "https://rubygems.org"

gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
gem "rspec", "~> 2.14.1", :group=>:test
gem "jruby-openssl", "~> 0.9.20", :group=>:test
gem "rails", "~> 3.0.20"

9 changes: 7 additions & 2 deletions gemfiles/rails30.gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ GEM
erubis (2.6.6)
abstract (>= 1.0.0)
i18n (0.5.4)
jruby-openssl (0.9.21-java)
json (1.8.1-java)
mail (2.2.20)
activesupport (>= 2.3.6)
Expand Down Expand Up @@ -61,7 +62,7 @@ GEM
rake (>= 0.8.7)
rdoc (~> 3.4)
thor (~> 0.14.4)
rake (10.3.2)
rake (10.4.2)
rdoc (3.12.2)
json (~> 1.4)
rspec (2.14.1)
Expand All @@ -82,6 +83,10 @@ PLATFORMS
java

DEPENDENCIES
jruby-openssl (~> 0.9.20)
rails (~> 3.0.20)
rake (~> 10.3.1)
rake (~> 10.4.2)
rspec (~> 2.14.1)

BUNDLED WITH
1.14.6
Loading

0 comments on commit 160e933

Please sign in to comment.