Skip to content

Commit 2287eaa

Browse files
authored
Merge pull request #262 from chadlwilson/merge-1.1.x-changes
Merge 1.1 into master (redux - with all specs passing + bumped dependency minor versions)
2 parents 73be8e9 + b56fb79 commit 2287eaa

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+881
-648
lines changed

.github/workflows/maven.yml

+11-5
Original file line numberDiff line numberDiff line change
@@ -16,21 +16,27 @@ on:
1616

1717
jobs:
1818
build:
19-
19+
name: JRuby ${{ matrix.jruby_version }} / Java ${{ matrix.java_version }}
2020
runs-on: ubuntu-latest
2121

22+
strategy:
23+
matrix:
24+
java_version: [ '8', '11', '17', '21' ]
25+
jruby_version: [ '9.3.15.0', '9.4.9.0' ]
26+
fail-fast: false
27+
2228
steps:
2329
- uses: actions/checkout@v4
24-
- name: Set up JDK 8
30+
- name: Set up JDK
2531
uses: actions/setup-java@v4
2632
with:
27-
java-version: '8'
33+
java-version: ${{ matrix.java_version }}
2834
distribution: 'temurin'
2935
cache: maven
3036
- name: Build with Maven
31-
run: mvn -B install --file pom.xml
37+
run: mvn -B install --file pom.xml -Djruby.version=${{ matrix.jruby_version }}
3238

3339
# Uploads the full dependency graph to GitHub to improve the quality of Dependabot alerts this repository can receive
3440
- name: Update dependency graph
3541
uses: advanced-security/maven-dependency-submission-action@571e99aab1055c2e71a1e2309b9691de18d6b7d6
36-
if: github.head_ref == 'refs/heads/master'
42+
if: github.head_ref == 'refs/heads/master' && matrix.java_version == '8' && startsWith(matrix.jruby_version, '9.4')

Appraisals

+13-2
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,12 @@ appraise "rails30" do
77
end
88

99
appraise "rails31" do
10+
gem "i18n", "< 0.7"
1011
gem "rails", "~> 3.1.12"
1112
end
1213

1314
appraise "rails32" do
15+
gem "i18n", "< 0.7"
1416
gem "rails", "~> 3.2.21"
1517
end
1618

@@ -19,11 +21,20 @@ appraise "rails40" do
1921
end
2022

2123
appraise "rails41" do
22-
gem "rails", "~> 4.1.10"
24+
gem "rails", "~> 4.1.16"
2325
end
2426

2527
appraise "rails42" do
26-
gem "rails", "~> 4.2.1"
28+
gem "mime-types", "< 3", :require => false
29+
gem "rails", "~> 4.2.9"
30+
end
31+
32+
appraise "rails50" do
33+
gem "rails", "~> 5.0.5"
34+
end
35+
36+
appraise "rails51" do
37+
gem "rails", "~> 5.1.2"
2738
end
2839

2940
appraise "railsNG" do

Gemfile.lock

+6-4
Original file line numberDiff line numberDiff line change
@@ -5,25 +5,27 @@ GEM
55
bundler
66
rake
77
diff-lcs (1.5.1)
8-
rack (2.2.9)
8+
rack (2.2.10)
99
rake (13.2.1)
1010
rspec (3.13.0)
1111
rspec-core (~> 3.13.0)
1212
rspec-expectations (~> 3.13.0)
1313
rspec-mocks (~> 3.13.0)
14-
rspec-core (3.13.0)
14+
rspec-core (3.13.2)
1515
rspec-support (~> 3.13.0)
16-
rspec-expectations (3.13.1)
16+
rspec-expectations (3.13.3)
1717
diff-lcs (>= 1.2.0, < 2.0)
1818
rspec-support (~> 3.13.0)
19-
rspec-mocks (3.13.1)
19+
rspec-mocks (3.13.2)
2020
diff-lcs (>= 1.2.0, < 2.0)
2121
rspec-support (~> 3.13.0)
2222
rspec-support (3.13.1)
2323

2424
PLATFORMS
2525
universal-java-1.8
2626
universal-java-11
27+
universal-java-17
28+
universal-java-21
2729

2830
DEPENDENCIES
2931
appraisal (< 1.0)

History.md

+34
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,37 @@
1+
## 1.1.22
2+
3+
- compile using Java 6 source compat
4+
- update (bundled) rack to 1.6.13
5+
- avoid NativeException - not used on recent JRuby
6+
- avoid Fixnum warning - assume recent JRuby
7+
- Add error message to log when runtime error is handled (#213)
8+
9+
## 1.1.21 (17/09/17)
10+
11+
- update (bundled) rack to 1.6.8
12+
- add Rack::Handler::Servlet::DefaultEnv#get_header (#212)
13+
missing methods to handle ActionController::Base#reset_session
14+
- can only safely stream natively on ActionDispatch <= 3.2 (#210)
15+
(broken Rails streaming for Rails 4.x)
16+
- when handling OPTION calls ignore both 'Date' and 'Allow' headers (#205)
17+
18+
## 1.1.20 (22/01/16)
19+
20+
- pre-maturely avoid Ruby frozen string literals coming at us ... ''.dup meh!
21+
- allow to boot when RAILS_ROOT/public directory does not exist (closes #197)
22+
- for better booter detection - export public path after working dir was changed
23+
- `ActionController::Base` provides a method `servlet_response` to return the
24+
`java.servlet_response` rack env (#201)
25+
- adjust jruby home dir fallback (for default $LOAD_PATH) correctly on 9K and --2.0
26+
- servlet env should behave on `fetch` and `[]` like a Hash (nil value can be set)
27+
28+
## 1.1.19 (01/07/15)
29+
30+
- update (bundled) rack to 1.5.5
31+
- servlet attrs with null/false values should not end up with an '' env value (#195)
32+
- tune ErrorApp + ShowStatus to respect set 'rack.showstatus.detail' (#194)
33+
- allow for more `JRuby::Rack::ErrorApp` customizations + retrieve cause when needed
34+
135
## 1.1.18 (13/01/15)
236

337
- back-port Rack::ShowStatus to be used with out ErrorApp (contains XSS fix #190)

LICENSE.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#--
22
# The MIT License
33
#
4-
# Copyright (c) 2012-2014 Karol Bucek, LTD
4+
# Copyright (c) 2012-2016 Karol Bucek, LTD.
55
# Copyright (c) 2010-2012 Engine Yard, Inc.
66
# Copyright (c) 2007-2009 Sun Microsystems, Inc.
77
#

Rakefile

+10-5
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,16 @@ end
5454
desc "Unpack the rack gem"
5555
task :unpack_gem => "target" do |t|
5656
target = File.expand_path(t.prerequisites.first)
57-
spec = Gem.loaded_specs["rack"]
58-
if spec.respond_to?(:cache_file)
59-
gem_file = spec.cache_file
60-
else
61-
gem_file = File.join(spec.installation_path, 'cache', spec.file_name)
57+
spec = Gem.loaded_specs['rack']
58+
# JRuby <= 1.7.20 does not handle respond_to? with method_missing right
59+
# ... issue with Bundler::StubSpecification wrapping (in bundler 1.10.x)
60+
unless ( gem_file = spec.cache_file rescue nil )
61+
#if defined?(::Bundler) && ::Bundler.const_defined?(:StubSpecification) # since Bundler 1.10.1
62+
# spec = spec.to_spec if spec.is_a?(::Bundler::StubSpecification)
63+
#else
64+
# spec = spec.to_spec if spec.respond_to?(:to_spec)
65+
#end
66+
gem_file = File.join(spec.base_dir, 'cache', spec.file_name)
6267
end
6368
unless uptodate?("#{target}/vendor/rack.rb", [__FILE__, gem_file])
6469
mkdir_p "target/vendor"

examples/sinatra/Gemfile

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
source 'https://rubygems.org'
22

3-
gem 'sinatra'
3+
gem 'sinatra', '< 4.0'
4+
gem 'webrick'
5+
gem "jruby-rack", "~> 1.2"
6+
gem 'rack', '2.2.8'

gemfiles/rails23.gemfile

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22

33
source "https://rubygems.org"
44

5-
gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
5+
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
66
gem "rspec", "~> 2.14.1", :group=>:test
7+
gem "jruby-openssl", "~> 0.9.20", :group=>:test
78
gem "rails", "~> 2.3.18"
89

gemfiles/rails23.gemfile.lock

+7-2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ GEM
1212
activesupport (= 2.3.18)
1313
activesupport (2.3.18)
1414
diff-lcs (1.2.5)
15+
jruby-openssl (0.9.21-java)
1516
rack (1.1.6)
1617
rails (2.3.18)
1718
actionmailer (= 2.3.18)
@@ -20,7 +21,7 @@ GEM
2021
activeresource (= 2.3.18)
2122
activesupport (= 2.3.18)
2223
rake (>= 0.8.3)
23-
rake (10.3.2)
24+
rake (10.4.2)
2425
rspec (2.14.1)
2526
rspec-core (~> 2.14.0)
2627
rspec-expectations (~> 2.14.0)
@@ -34,6 +35,10 @@ PLATFORMS
3435
java
3536

3637
DEPENDENCIES
38+
jruby-openssl (~> 0.9.20)
3739
rails (~> 2.3.18)
38-
rake (~> 10.3.1)
40+
rake (~> 10.4.2)
3941
rspec (~> 2.14.1)
42+
43+
BUNDLED WITH
44+
1.14.6

gemfiles/rails30.gemfile

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22

33
source "https://rubygems.org"
44

5-
gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
5+
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
66
gem "rspec", "~> 2.14.1", :group=>:test
7+
gem "jruby-openssl", "~> 0.9.20", :group=>:test
78
gem "rails", "~> 3.0.20"
89

gemfiles/rails30.gemfile.lock

+7-2
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ GEM
3434
erubis (2.6.6)
3535
abstract (>= 1.0.0)
3636
i18n (0.5.4)
37+
jruby-openssl (0.9.21-java)
3738
json (1.8.1-java)
3839
mail (2.2.20)
3940
activesupport (>= 2.3.6)
@@ -61,7 +62,7 @@ GEM
6162
rake (>= 0.8.7)
6263
rdoc (~> 3.4)
6364
thor (~> 0.14.4)
64-
rake (10.3.2)
65+
rake (10.4.2)
6566
rdoc (3.12.2)
6667
json (~> 1.4)
6768
rspec (2.14.1)
@@ -82,6 +83,10 @@ PLATFORMS
8283
java
8384

8485
DEPENDENCIES
86+
jruby-openssl (~> 0.9.20)
8587
rails (~> 3.0.20)
86-
rake (~> 10.3.1)
88+
rake (~> 10.4.2)
8789
rspec (~> 2.14.1)
90+
91+
BUNDLED WITH
92+
1.14.6

gemfiles/rails31.gemfile

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
source "https://rubygems.org"
44

5-
gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
5+
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
66
gem "rspec", "~> 2.14.1", :group=>:test
7+
gem "jruby-openssl", "~> 0.9.20", :group=>:test
8+
gem "i18n", "< 0.7"
79
gem "rails", "~> 3.1.12"
810

gemfiles/rails31.gemfile.lock

+13-7
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,14 @@ GEM
3535
erubis (2.7.0)
3636
hike (1.2.3)
3737
i18n (0.6.11)
38-
json (1.8.1-java)
38+
jruby-openssl (0.9.21-java)
39+
json (1.8.2-java)
3940
mail (2.4.4)
4041
i18n (>= 0.4.0)
4142
mime-types (~> 1.16)
4243
treetop (~> 1.4.8)
4344
mime-types (1.25.1)
44-
multi_json (1.10.1)
45+
multi_json (1.11.0)
4546
polyglot (0.3.5)
4647
rack (1.3.10)
4748
rack-cache (1.2)
@@ -50,7 +51,7 @@ GEM
5051
rack (>= 1.0.0)
5152
rack-ssl (1.3.4)
5253
rack
53-
rack-test (0.6.2)
54+
rack-test (0.6.3)
5455
rack (>= 1.0)
5556
rails (3.1.12)
5657
actionmailer (= 3.1.12)
@@ -67,7 +68,7 @@ GEM
6768
rake (>= 0.8.7)
6869
rdoc (~> 3.4)
6970
thor (~> 0.14.6)
70-
rake (10.3.2)
71+
rake (10.4.2)
7172
rdoc (3.12.2)
7273
json (~> 1.4)
7374
rspec (2.14.1)
@@ -78,7 +79,7 @@ GEM
7879
rspec-expectations (2.14.5)
7980
diff-lcs (>= 1.1.3, < 2.0)
8081
rspec-mocks (2.14.6)
81-
sprockets (2.0.4)
82+
sprockets (2.0.5)
8283
hike (~> 1.2)
8384
rack (~> 1.0)
8485
tilt (~> 1.1, != 1.3.0)
@@ -87,12 +88,17 @@ GEM
8788
treetop (1.4.15)
8889
polyglot
8990
polyglot (>= 0.3.1)
90-
tzinfo (0.3.41)
91+
tzinfo (0.3.44)
9192

9293
PLATFORMS
9394
java
9495

9596
DEPENDENCIES
97+
i18n (< 0.7)
98+
jruby-openssl (~> 0.9.20)
9699
rails (~> 3.1.12)
97-
rake (~> 10.3.1)
100+
rake (~> 10.4.2)
98101
rspec (~> 2.14.1)
102+
103+
BUNDLED WITH
104+
1.14.6

gemfiles/rails32.gemfile

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
source "https://rubygems.org"
44

5-
gem "rake", "~> 10.3.1", :group=>:test, :require=>nil
5+
gem "rake", "~> 10.4.2", :group=>:test, :require=>nil
66
gem "rspec", "~> 2.14.1", :group=>:test
7+
gem "jruby-openssl", "~> 0.9.20", :group=>:test
8+
gem "i18n", "< 0.7"
79
gem "rails", "~> 3.2.21"
810

0 commit comments

Comments
 (0)