Bug 43729 - Migrate to Jetty6 for working AJP support
Summary: Migrate to Jetty6 for working AJP support
Status: NEW
Alias: None
Product: Lenya
Classification: Unclassified
Component: Miscellaneous (show other bugs)
Version: Trunk
Hardware: Other other
: P2 major
Target Milestone: 2.0.1
Assignee: Lenya Developers
URL:
Keywords:
Depends on: 43864
Blocks:
  Show dependency tree
 
Reported: 2007-10-29 15:15 UTC by J
Modified: 2007-11-16 11:55 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description J 2007-10-29 15:15:27 UTC
when jetty is used with an apache httpd in front and the ajp connector, apache
has problems with the data from jetty:
[Mon Oct 29 23:08:28 2007] [error] ajp_parse_data: Wrong chunk length. Length of
chunk is 8185, expected length is 8184.
[Mon Oct 29 23:08:28 2007] [error] (120007)APR does not understand this error
code: proxy: send body failed to (null) (*)

a bugzilla entry in apache httpd suggests that this might be jetty's fault (an
off-by-one error due to a terminating \0 that should not be counted as
payload...): http://issues.apache.org/bugzilla/show_bug.cgi?id=39528

this prevents jetty from being used in proxied environments with ajp. plain http
proxy does not work, because it breaks https requests, because jetty does not
get to see if a user originally requested a page through ssl, hence it produces
http links instead of https. 

maybe we need to upgrade our jetty eventually...
Comment 1 J 2007-10-29 17:03:03 UTC
looks like it's a slightly different issue that has been fixed already:
http://jira.codehaus.org/browse/JETTY-407
time to upgrade jetty i think...

i'm setting this on the agenda for 2.0. the goal is to have a proxied testing
environment using jetty and to provide apache httpd vhost configs that will
enable users and developers to easily test in a proxy setting and to serve as
example configs. currently, people are using wildly different proxy setups,
there are no established best practices yet and thus it's very hard to compare
symptoms and make sense of bug reports regarding proxying...
Comment 2 J 2007-10-30 09:14:34 UTC
confirmed. the ajp connector works with jetty 6.1.
i've committed tools/proxytest, see jetty6.xml on how to run lenya with the new
version. so far, everything seems to work, except the jetty6 configuration could
use some polish.
there is now a preliminary proxy testing scaffold, but it's quite broken atm.

it would be great if some people could do some testing on jetty6. maybe we can
up it before we go into code freeze? wdyt?
Comment 3 Richard Frovarp 2007-10-30 09:43:51 UTC
I think it would be good to get it up and going with Jetty 6.1. In fact
yesterday I was starting to weigh the pros and cons of Jetty vs Tomcat due to
the fact I want to move to mod_proxy_ajp, and was going to test Jetty out today.
Looks like I'll be testing with a new version when I get back from lunch.
Comment 4 Richard Frovarp 2007-10-30 13:18:26 UTC
I've done some testing but am having issues. I get a bunch of redirects all over
the place that eventually cause it to not work. I don't have Apache 2.2 on my
machine, so I'm using different machine with different domains. So my test setup
is a bit different from the reference. 

I can however tell you that Jetty 6.1 will listen via IPV6, and Apache will send
it requests via V6.
Comment 5 J 2007-10-31 01:25:32 UTC
yeah, the proxy test setup is not working for me, either. still very much work
in progress. the redirects is where i'm stuck, too.

but did you test jetty6 w/o proxying? that works for me, flawlessly. i'd like to
hear more about that. you don't need to change anything, jetty6 is configured
both for ajp on port 8009 and for http on 8888, so you can pretty much drop it
in for the current jetty.
Comment 6 Richard Frovarp 2007-10-31 07:37:05 UTC
(In reply to comment #5)

> but did you test jetty6 w/o proxying? that works for me, flawlessly. i'd like to
> hear more about that. you don't need to change anything, jetty6 is configured
> both for ajp on port 8009 and for http on 8888, so you can pretty much drop it
> in for the current jetty.
> 

I just did some testing there. I haven't had any issues with jetty6 in
particular. Since it isn't in the root context, I've been having trouble there.
I don't have a tomcat install so I'm not sure if this is a problem with jetty6
or a generic problem with not having lenya under the root context.
Comment 7 J 2007-11-05 11:25:15 UTC
i'd say let's try and release 2.0.1 with jetty6 included, but given the current
code freeze for 2.0, it's probably better to postpone further work on it until
after the release.
Comment 8 J 2007-11-16 11:55:17 UTC
just a quick summary: there have been some success reports with jetty6 in
general, and using it as an ajp proxy in particular.
proxy- and context-related bugs have mostly been fixed.

one tricky issue remains: bug 43864 seems to be jetty-specific. at least jann
and andreas can't reproduce it on tomcat.

additionally, we need to provide a robust start script that will work on both
linux and windows and ideally takes its configuration from
local.build.properties, and then it should be ready for 2.0.1