jruby-rack 1.2.8 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3bcf16ccfae94d36851adb3d1ccf9f0cec2784e69a67a4f3dfa5212488213084
4
- data.tar.gz: 98fde912b9f55b168def3daf36f740a2ea353c6deb7e3a10ad36bcc0b368144b
3
+ metadata.gz: 480bad7f58a728015d2d14bbf86ec8296dc3620cdd6d10a4e5d0ee7cf747d0e6
4
+ data.tar.gz: fc3591afbf787931dd71a41422f156b508dcd161c487672009aada3ae183caf5
5
5
  SHA512:
6
- metadata.gz: aa91dc347011e4cb54163655e3a9ef7b5c9924f0d9eb0c76d1204f0cfc01b71b4211422b529b6bbd370f4198298ef42a1e2668d7cb12542ce37aacd7fff87fc3
7
- data.tar.gz: cc968a1cd0ab939e0d63a8ada0e87baab643087a93727127306b80939f3817505800769395077c6ba1120ea19d5f98b78db0d855959cc1aa330484656046d869
6
+ metadata.gz: f4d4ba89f604deebbd80d7213c69e964f18d33373c25bf80a431338d659844e62e02311300c6c3c6262cdf38c335bf290797e8f8432aeffbfbb478a1aa274c9e
7
+ data.tar.gz: aa83558ba91a6a38e13801a78b3d0f7540727a8673036a85aca355908010afcb10a2a168ae21449b7cc8be885e5a40862ee5bcfd2c16199fd48eafca174e9887
data/CHANGELOG.md CHANGED
@@ -1,3 +1,43 @@
1
+ ## 1.3.0 (UNRELEASED)
2
+
3
+ - Officially support Javax Servlet API 4.0 (JEE 8)
4
+ - Refactor logging for more sane defaults
5
+ - Remove long-deprecated configuration and API functionality
6
+
7
+ For most users this should be a minor upgrade; as long as you do not depend on functionality deprecated within
8
+ JRuby-Rack 1.2.x, EOL JRuby or EOL Rails versions.
9
+
10
+ Breaking compatibility changes
11
+ - Drop support for JRuby 9.x (and thus Java < 21)
12
+ - Drop support for Rails < 7.2
13
+ - Drop JMS support
14
+
15
+ Breaking behavioral changes
16
+ - Change context listener to throw by default in case of an exception during initialization
17
+ - Change rails context listener to assume a thread-safe application by default
18
+ - Rack is no longer vendored inside the jar, so applications must ensure rack is provided via bundler or GEM_PATH
19
+
20
+ Breaking configuration capability changes
21
+ - Drop `jruby.rack.jruby.version` and `jruby.rack.rack.release` keys from rack `env` Hash
22
+ - Drop deprecated and undocumented jruby-rack 1.0 backwards compat properties `jruby.runtime.timeout.sec`, `jruby.runtime.initializer.threads`, `jruby.init.serial`, `jruby.rack.request.size.threshold.bytes`
23
+ - Drop deprecated `jruby.rack.ignore.env` property, replaced long ago by `jruby.runtime.env` and optional `jruby.runtime.env.rubyopt`
24
+ - Drop deprecated `jruby.rack.filter.*` properties, replaced long ago by init parameters `addsHtmlToPathInfo` and `verifiesHtmlResource`
25
+ - Drop handling of `# rack.version` magic comments inside `config.ru` files, replaced by bundler or user-managed `GEM_PATH`
26
+
27
+ Breaking Java API changes (only relevant for users extending the Java API)
28
+ - Drop unnecessary `jruby.compat.version` and `RackConfig.getCompatVersion()` API
29
+ - Drop deprecated `org.jruby.rack.RackInput` alias for `org.jruby.rack.ext.Input` class
30
+ - Drop/rename deprecated `RackConfig` and `ServletRackEnvironment` API methods per their earlier comments
31
+ - Drop deprecated `RackLogger` string (`level`) constants
32
+ - Custom `RackLogger` implementations must accept `CharSequence` rather than `String` to allow `RubyString` passthrough
33
+ - Rename deprecated `JRuby::Rack::ServletLog` to `JRuby::Rack::ErrorLog` for clarity, despite usage only in servlet contexts.
34
+
35
+ Breaking Ruby API changes (only relevant for users extending the Ruby API)
36
+ - Drop deprecated `JRuby::Rack::RailsFileSystemLayout` alias for `JRuby::Rack::FileSystemLayout`
37
+ - Drop deprecated `JRuby::Rack::Errors` alias for `JRuby::Rack::ErrorApp`
38
+ - Drop deprecated `Rack::Handler::Servlet::Env` and `Rack::Handler::Servlet::LazyEnv` types (replaced by `DefaultEnv`)
39
+ - Drop deprecated setting of global `$servlet_context` variable during embedded usage (replaced by `JRuby::Rack.context`)
40
+
1
41
  ## 1.2.8
2
42
 
3
43
  - Improve isolation and bundler version/CLI boot issues with more opinionated boot process (#461)
@@ -187,9 +227,9 @@ Changes from 1.1.15 apply since the previous release got yanked due a regression
187
227
  to handle custom lazy-bound keys but can not use a default proc (#132)
188
228
  - support the renew (and skip) session option with servlet store (#131)
189
229
  - improve ENV isolation with booted Ruby runtimes
190
- * jruby.rack.env replaces jruby.rack.ignore.env (now deprecated)
230
+ * jruby.runtime.env replaces jruby.rack.ignore.env (now deprecated)
191
231
  * make sure RUBYOPT is ignored (with backwards compat)
192
- * jruby.rack.env.rubyopt for finer RUBYOPT behavior control
232
+ * jruby.runtime.env.rubyopt for finer RUBYOPT behavior control
193
233
  * allow env value to be specified from config
194
234
  - solve the rackup "chicken - egg" problem with a plain Rack app
195
235
  * with a magic comment in config.ru # rack.version: ~>1.3.6
data/README.md CHANGED
@@ -13,11 +13,12 @@ For more information on Rack, visit http://rack.github.io/.
13
13
 
14
14
  ## Compatibility
15
15
 
16
- | JRuby-Rack Series | Status | Rack | JRuby | Java | Rails | Servlet API (min → mostly supported) | Notes |
17
- |----------------------------------------------------------------|---------------|-----------|------------|------|-----------|--------------------------------------|-------|
18
- | [**1.2**](https://github.com/jruby/jruby-rack/tree/1.2-stable) | EOL @ 2026-09 | 2.2 | 9.3 → 10.1 | 8+ | 5.0 → 8.0 | 3.0 → 4.0 (Java EE 6 → 7) | |
19
- | [**1.1**](https://github.com/jruby/jruby-rack/tree/1.1-stable) | EOL @ 2024-05 | 1.x → 2.2 | 1.69.4 | 6+ | 2.15.2 | 2.5 → 4.0 (Java EE 5 → 7) | |
20
- | [**1.0**](https://github.com/jruby/jruby-rack/tree/1.0.10) | EOL @ 2011-11 | 0.91.x | 1.11.9 | 5+ | 2.1 → 3.x | 2.5 (Java EE 5) | |
16
+ | JRuby-Rack Series | Status | Rack | JRuby | Java | Rails | Servlet API (min → mostly supported) | Notes |
17
+ |----------------------------------------------------------------|---------------|-----------|-------------|------|-----------|--------------------------------------|-----------------------------------------------------------|
18
+ | [**1.3**](https://github.com/jruby/jruby-rack/tree/1.3-stable) | Maintained | 2.2 | 10.0 → 10.1 | 21+ | 7.2 → 8.0 | 4.0 (Java EE 8) | ✅ _Unofficial_: Rails 6.1 → 7.1 untested, but likely OK. |
19
+ | [**1.2**](https://github.com/jruby/jruby-rack/tree/1.2-stable) | EOL @ 2026-09 | 2.2 | 9.310.1 | 8+ | 5.08.0 | 3.0 → 4.0 (Java EE 6 → 7) | |
20
+ | [**1.1**](https://github.com/jruby/jruby-rack/tree/1.1-stable) | EOL @ 2024-05 | 1.x2.2 | 1.69.4 | 6+ | 2.1 → 5.2 | 2.5 → 4.0 (Java EE 5 → 7) | |
21
+ | [**1.0**](https://github.com/jruby/jruby-rack/tree/1.0.10) | EOL @ 2011-11 | 0.9 → 1.x | 1.1 → 1.9 | 5+ | 2.1 → 3.x | 2.5 (Java EE 5) | |
21
22
 
22
23
  ## Getting Started
23
24
 
@@ -150,7 +151,8 @@ using is `org.jruby.rack.RackFilter`, the filter supports the following
150
151
  original URI. However, this behavior may confuse other servlets in your
151
152
  application that have a wildcard mapping. Defaults to true.
152
153
  - **verifiesHtmlResource** used with the previous parameter to make sure the
153
- requested static resource exists before adding the .html request URI suffix
154
+ requested static resource exists before adding the .html request URI suffix.
155
+ Defaults to false.
154
156
 
155
157
  The application can also be configured to dispatch through a servlet instead of
156
158
  a filter, the servlet class name is `org.jruby.rack.RackServlet`.
@@ -179,10 +181,11 @@ Several aspects of Rails are automatically set up for you.
179
181
  ## JRuby Runtime Management
180
182
 
181
183
  JRuby runtime management and pooling is done automatically by the framework.
182
- In the case of Rails, runtimes are pooled by default. For other Rack applications a
183
- single shared runtime is created and shared for every request by default.
184
+ For Rack-only applications (and Rails ones from jruby-rack >= 1.3), a single
185
+ shared runtime is created and shared for every request by default.
186
+
184
187
  If `jruby.min.runtimes` and `jruby.max.runtimes` values are
185
- specified pooling is supported for plain Rack applications as well.
188
+ specified pooling of runtimes can be enabled for both types of applications.
186
189
 
187
190
  We do recommend to boot your runtimes up-front to avoid the cost of initializing
188
191
  one while a request kicks in and find the pool empty, this can be easily avoided
@@ -227,10 +230,9 @@ as context init parameters in web.xml or as VM-wide system properties.
227
230
  - `jruby.runtime.env`: Allows to set a custom ENV hash for your Ruby environment
228
231
  and thus insulate the application from the environment it is running. By setting
229
232
  this option to en empty string (or 'false') it acts as if the ENV hash was
230
- cleared out (similar to the now deprecated `jruby.rack.ignore.env` option).
231
- - `jruby.runtime.env.rubyopt`: This option is used for compatibility with the
232
- (deprecated) `jruby.rack.ignore.env` option since it cleared out the ENV after
233
- RUBYOPT has been processed, by setting it to true ENV['RUBYOPT'] will be kept.
233
+ cleared out (similar to the now removed `jruby.rack.ignore.env` option).
234
+ - `jruby.runtime.env.rubyopt`: Set to true to cause ENV['RUBYOPT']
235
+ to be retained even when using `jruby.runtime.env` to override the environment.
234
236
  - `jruby.rack.env.gem_path`: If set to `true` (the default) jruby-rack will
235
237
  ensure ENV['GEM_PATH'] is altered to include the `gem.path` above. If you set it to a
236
238
  value, this value will be used as GEM_PATH, overriding the environment and
@@ -255,20 +257,6 @@ as context init parameters in web.xml or as VM-wide system properties.
255
257
  been previously read this leads to a limitation (Rack won't see the POST paras).
256
258
  Thus an alternate pure 'servlet' env "conversion" is provided that maps servlet
257
259
  parameters (and cookies) directly to Rack params, avoiding Rack's input parsing.
258
- - `jruby.rack.filter.adds.html`:
259
- **deprecated** use `addsHtmlToPathInfo` filter config init parameter.
260
- The default behavior for Rails and many other Ruby applications is to add an
261
- *.html* extension to the resource and attempt to handle it before serving a
262
- dynamic request on the original URI.
263
- However, this behavior may confuse other servlets in your application that
264
- have a wildcard mapping. Defaults to true.
265
- - `jruby.rack.filter.verify.resource.exists`:
266
- **deprecated** use `verifiesHtmlResource` filter config init parameter.
267
- If `jruby.rack.filter.adds.html` is true, then this setting, when true, adds
268
- an additional check using `ServletContext#getResource` to verify that the
269
- *.html* resource exists. Default is false.
270
- (Note that apparently some servers may not implement `getResource` in the way
271
- that is expected here, so in that case this setting won't matter.)
272
260
 
273
261
  ## Initialization
274
262
 
@@ -278,24 +266,10 @@ Ruby environment before booting the application. You can create a file called
278
266
  These files, if found, will be evaluated before booting the Rack environment,
279
267
  allowing you to set environment variables, load scripts, etc.
280
268
 
281
- For plain Rack applications, JRuby-Rack also supports a magic comment to solve
282
- the "rackup" chicken-egg problem (you need Rack's builder loaded before loading
283
- the `config.ru`, yet you may want to setup the gem version from within the rackup
284
- file). As we ship with the Rack gem bundled, otherwise when executing the
285
- provided `config.ru` the bundled (latest) version of Rack will get loaded.
286
-
287
- Use `rack.version` to specify the Rack gem version to be loaded before rackup :
288
-
289
- ```ruby
290
- # encoding: UTF-8
291
- # rack.version: ~>2.2.10 (before code is loaded gem '~>2.2.10' will be called)
292
- ```
293
-
294
- Or the equivalent of doing `bundle exec rackup ...` if you're using Bundler :
295
-
296
- ```ruby
297
- # rack.version: bundler (require 'bundler'; Bundler.setup; before loading the script)
298
- ```
269
+ JRuby-Rack does not vendor Rack - the application is expected to provide it, just like
270
+ with other Ruby web servers. For applications depending on `jruby-rack` via jar (rather than gem),
271
+ this means having `rack` in the `Gemfile` (usually implied by the web framework);
272
+ or available on the application's gem path.
299
273
 
300
274
  ## Logging
301
275
 
@@ -409,7 +383,6 @@ Releasing must be done by users authorized to push to the `org.jruby` group ID o
409
383
  * Update the versions in `pom.xml` and `src/main/ruby/jruby/rack/version.rb` to the release version
410
384
  * Commit the version update locally
411
385
  * Run `./mvnw deploy -Prelease` to build, sign, and push all artifacts to Maven Central staging
412
- * NOTE: the release will automatically publish once validated by Maven Central
413
386
  * Confirm the release completes publishing at `https://central.sonatype.org`
414
387
  * `rake clean gem SKIP_SPECS=true` and push the gem
415
388
  * Tag the release version in git
@@ -8,6 +8,6 @@
8
8
 
9
9
  module JRuby
10
10
  module Rack
11
- VERSION = '1.2.8'
11
+ VERSION = '1.3.0'
12
12
  end
13
13
  end
Binary file
data/lib/jruby-rack.rb CHANGED
@@ -1,7 +1,7 @@
1
1
 
2
2
  module JRubyJars
3
3
  def self.jruby_rack_jar_path
4
- File.expand_path("../jruby-rack-1.2.8.jar", __FILE__)
4
+ File.expand_path("../jruby-rack-1.3.0.jar", __FILE__)
5
5
  end
6
6
  require jruby_rack_jar_path if defined?(JRUBY_VERSION)
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jruby-rack
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.8
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Sieger
@@ -10,7 +10,21 @@ authors:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
  date: 2026-08-31 00:00:00.000000000 Z
13
- dependencies: []
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: rack
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: 2.2.0
21
+ type: :runtime
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: 2.2.0
14
28
  description: JRuby-Rack is a combined Java and Ruby library that adapts the Java Servlet
15
29
  API to Rack. For JRuby only.
16
30
  email:
@@ -22,7 +36,7 @@ files:
22
36
  - CHANGELOG.md
23
37
  - LICENSE.txt
24
38
  - README.md
25
- - lib/jruby-rack-1.2.8.jar
39
+ - lib/jruby-rack-1.3.0.jar
26
40
  - lib/jruby-rack.rb
27
41
  - lib/jruby/rack/version.rb
28
42
  homepage: http://jruby.org
@@ -36,7 +50,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
36
50
  requirements:
37
51
  - - ">="
38
52
  - !ruby/object:Gem::Version
39
- version: 2.6.0
53
+ version: 3.4.0
40
54
  required_rubygems_version: !ruby/object:Gem::Requirement
41
55
  requirements:
42
56
  - - ">="
Binary file