I should clarify that it was Jayson Falkner who provided that answer. :-) As for whether JRun is playing fast and loose with the specs, I'd suspect not, but I've not read them so can't say for sure. I guess what you're asserting is that since Tomcat is the reference implementation, anything that works on it should be considered "up to spec". That seems reasonable, but I look forwarded to any MM folks (or others) who might offer defense for JRun's approach in this particular feature.
/charlie > -----Original Message----- > From: Dave Jones [mailto:[EMAIL PROTECTED]] > Sent: Saturday, August 03, 2002 2:03 AM > To: JRun-Talk > Subject: Re: sendRedirect + relative path = bug? > > > Charlie, > That's the answer I came up with as well (i.e. using > request.getContext()). Never got a satisfactory answer from any > Macromediites on the JRun forum. This is the second apparent bug > I've encountered in converting a Tomcat app to JRun My sense is > that JRun more loosely interprets the servlet specs than Tomcat. > > Dave > > > > At 10:06 PM 8/2/02 -0400, you wrote: > >This is a pain, but, you can do it using HttpServletRequest > >getContextPath() to always ensure the corrent context path is > there. i.e.: > > > >response.sendRedirect(request.getContext()+"/web/" + nextPage); > > > >Now, the shameless plug. Keep an eye on http://www.jspbook.com. Kevin > >Jones and I have been working hard to put out a good, bleeding-edge book > >on JSP 2.0 and Servlets 2.4(it will be out soon but after the specs are > >final of course ;). This issue gets a direct mention :) > > > >Cheers, > > > >Jayson Falkner > >[EMAIL PROTECTED] > > > >charlie arehart wrote: > > > Dave, did you ever find an answer to this? I'd be curious > about it myself > > > > > > /charlie > > > > > > PS Can't do any testing to offer answers due a recent crash > > I'm in the midst > > > of recovering from. > > > > > > > > >>-----Original Message----- > > >>From: Dave Jones [mailto:[EMAIL PROTECTED]] > > >>Sent: Wednesday, July 24, 2002 3:02 PM > > >>To: JRun-Talk > > >>Subject: sendRedirect + relative path = bug? > > >> > > >> > > >>In another in the series of travails in converting an app from > > >>Tomcat to JRun, I've run into what seems to be a bug in JRun's > > >>implementation of sendRedirect. > > >> > > >>For example, the following statement: > > >> > > >>response.sendRedirect("../web/" + nextPage); > > >> > > >>throws the error: > > >> > > >>404 Not found > > >>http://hostname/servlet/../web/Dispatch.jsp?page=ProspectMaint.jsp > > >>&reset=true > > >> > > >>This works fine in Tomcat, but it seems pretty clear JRun is not > > >>resolving the relative path. > > >> > > >>Changing the statement to use an absolute path (e.g. "/web/") > > >>works, but since the absolute path resolves to the server root > > >>rather than context root, I prefer to use relative addressing so > > >>that I can easily move the app between development, staging and > > >>production environments. > > >> > > >>Is this a bug or are things done differently in the JRun world? > > >> > > >>TIA, > > >>Dave Jones > > >>NetEffect > > >> > > >> > > > > > > > > > ______________________________________________________________________ This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
