jruby-rack 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +16 -0
- data/README.md +41 -8
- data/lib/{jruby-rack-1.0.3.jar → jruby-rack-1.0.4.jar} +0 -0
- data/lib/jruby-rack.rb +1 -0
- data/lib/jruby/rack/version.rb +1 -1
- metadata +9 -9
data/History.txt
CHANGED
@@ -1,3 +1,19 @@
|
|
1
|
+
== 1.0.4
|
2
|
+
|
3
|
+
- Make sane defaults for app/gem/public paths when using
|
4
|
+
RailsFilesystemLayout (Kristian Meier)
|
5
|
+
- Add 'jruby.rack.slash.index' init param that forces / =>
|
6
|
+
/index.html. Fixes JRUBY_RACK-35 and makes Jetty 6 work without
|
7
|
+
having to configure dirAllowed in Jetty's default servlet.
|
8
|
+
- Switch to mostly relying on request URI and not so much servlet
|
9
|
+
path/path info. Makes Tomcat 7 work.
|
10
|
+
- Added rails.relative_url_append context parameter. This can be set in
|
11
|
+
your web.xml or similar to append a string to the end of the context
|
12
|
+
path when the RAILS_RELATIVE_URL_ROOT is set. This allows you to
|
13
|
+
host your rails app in a location other than the base context path
|
14
|
+
of your application. (Ben Rosenblum)
|
15
|
+
- Don't use toURI, following changes in JRuby 1.5.6.
|
16
|
+
|
1
17
|
== 1.0.3
|
2
18
|
|
3
19
|
- JRUBY-4892: Fix IO collapsing \r\n to \n on Windows
|
data/README.md
CHANGED
@@ -1,7 +1,5 @@
|
|
1
1
|
# JRuby-Rack
|
2
2
|
|
3
|
-
- http://jruby-rack.kenai.com/
|
4
|
-
|
5
3
|
JRuby-Rack is a lightweight adapter for the Java servlet environment
|
6
4
|
that allows any Rack-based application to run unmodified in a Java
|
7
5
|
servlet container. JRuby-Rack supports Rails, Merb, as well as any
|
@@ -12,13 +10,19 @@ For more information on Rack, visit http://rack.rubyforge.org.
|
|
12
10
|
# Getting Started
|
13
11
|
|
14
12
|
The easiest way to use JRuby-Rack is to get [Warbler][1]. Warbler
|
15
|
-
|
13
|
+
depends on the latest version of JRuby-Rack and ensures it gets placed in
|
16
14
|
your WAR file when it gets built.
|
17
15
|
|
18
|
-
If you're assembling your own WAR using other means, you
|
19
|
-
|
20
|
-
|
21
|
-
|
16
|
+
If you're assembling your own WAR using other means, you can install the
|
17
|
+
`jruby-rack` gem. It provides a method to located the jruby-rack jar file:
|
18
|
+
|
19
|
+
require 'fileutils'
|
20
|
+
require 'jruby-rack'
|
21
|
+
FileUtils.cp JRubyJars.jruby_rack_jar_path, '.'
|
22
|
+
|
23
|
+
Otherwise you'll need to download the [latest JRuby-Rack jar][2], drop
|
24
|
+
it into the WEB-INF/lib directory and configure the RackFilter in your
|
25
|
+
application's web.xml. Example web.xml snippets are as follows.
|
22
26
|
|
23
27
|
## For Rails
|
24
28
|
|
@@ -157,8 +161,37 @@ web.xml.
|
|
157
161
|
Merb application files. Defaults to `/WEB-INF`.
|
158
162
|
- `rails.env`: Specify the Rails environment to run. Defaults
|
159
163
|
to 'production'.
|
164
|
+
- `rails.relative_url_append`: Specify a path to be appended to the
|
165
|
+
ActionController::Base.relative_url_root after the context path. Useful
|
166
|
+
for running a rails app from the same war as an existing app, under
|
167
|
+
a sub-path of the main servlet context root.
|
160
168
|
- `merb.environment`: Specify the merb environment to run. Defaults to
|
161
169
|
`production`.
|
170
|
+
- `jruby.rack.logging`: Specify the logging device to use. Defaults to
|
171
|
+
`servlet_context`. See below.
|
172
|
+
- `jruby.rack.slash.index`: Force rewriting of requests that end in
|
173
|
+
'/' to be passed through to the container as '/index.html'. Default
|
174
|
+
is false, but is turned on for Jetty by default to avoid triggering
|
175
|
+
directory index pages.
|
176
|
+
|
177
|
+
## Logging
|
178
|
+
|
179
|
+
JRuby-Rack sets up a delegate logger for Rails that sends logging
|
180
|
+
output to `javax.servlet.ServletContext#log` by default. If you wish
|
181
|
+
to use a different logging system, set the `jruby.rack.logging`
|
182
|
+
context parameter as follows:
|
183
|
+
|
184
|
+
- `servlet_context` (default): Sends log messages to the servlet
|
185
|
+
context.
|
186
|
+
- `stdout`: Sends log messages to the standard output stream
|
187
|
+
`System.out`.
|
188
|
+
- `commons_logging`: Sends log messages to Apache commons-logging. You
|
189
|
+
still need to configure commons-logging with additional details.
|
190
|
+
- `slf4j`: Sends log messages to SLF4J. Again, SLF4J configuration is
|
191
|
+
left up to you.
|
192
|
+
|
193
|
+
For those loggers that require a specific named logger, set it in the
|
194
|
+
`jruby.rack.logging.name` context parameter.
|
162
195
|
|
163
196
|
# Building
|
164
197
|
|
@@ -276,5 +309,5 @@ The war should be ready to deploy to your Java application server.
|
|
276
309
|
- Chris Neukirchen, for Rack
|
277
310
|
- Sun Microsystems, for early project support
|
278
311
|
|
279
|
-
[1]: http://
|
312
|
+
[1]: http://caldersphere.rubyforge.org/warbler
|
280
313
|
[2]: http://repository.codehaus.org/org/jruby/rack/jruby-rack/
|
Binary file
|
data/lib/jruby-rack.rb
CHANGED
data/lib/jruby/rack/version.rb
CHANGED
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 1
|
7
7
|
- 0
|
8
|
-
-
|
9
|
-
version: 1.0.
|
8
|
+
- 4
|
9
|
+
version: 1.0.4
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Nick Sieger
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-08
|
17
|
+
date: 2010-12-08 00:00:00 -06:00
|
18
18
|
default_executable:
|
19
19
|
dependencies: []
|
20
20
|
|
@@ -28,12 +28,12 @@ extensions: []
|
|
28
28
|
extra_rdoc_files: []
|
29
29
|
|
30
30
|
files:
|
31
|
-
-
|
32
|
-
-
|
33
|
-
-
|
34
|
-
-
|
35
|
-
-
|
36
|
-
-
|
31
|
+
- History.txt
|
32
|
+
- LICENSE.txt
|
33
|
+
- README.md
|
34
|
+
- lib/jruby-rack-1.0.4.jar
|
35
|
+
- lib/jruby-rack.rb
|
36
|
+
- lib/jruby/rack/version.rb
|
37
37
|
has_rdoc: true
|
38
38
|
homepage: http://jruby.org
|
39
39
|
licenses: []
|