[MGNLWLS-10] Returned context path is incorrect for long URLs Created: 13/Nov/09  Updated: 26/Jun/15  Resolved: 26/Jun/15

Status: Closed
Project: Oracle WebLogic Compatibility
Component/s: None
Affects Version/s: 1.2
Fix Version/s: 1.3

Type: Bug Priority: Major
Reporter: Jan Haderka Assignee: Unassigned
Resolution: Outdated Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:

 Description   

In Weblogic 10.1 happens that when URL is longer then 150 characters and context path is short (4 characters), the context path returned by the request contains extra characters.



 Comments   
Comment by Magnolia International [ 13/Nov/09 ]

reopening so we don't forget to check if WL allows "deep" contextpaths
(according to spec, nothing speaks against having a context path containing multiple path elements)

Comment by Jan Haderka [ 13/Nov/09 ]

Except weblogic fails to deploy the webapp with such a context path every time i tried. But you are right we should allow it.
The issue is even more complicated. It occurs for the long URLs as stated above, but only if the first character after the slash ending the context path is a dot. So the urls pointing directly to dms are fine. While the urls pointing to .imaging run into the issue if they are long enough. Not having a sources for weblogic.servlet.internal.ServletRequestImpl (that's the class from which the wrong context path comes) it is difficult to figure out what exactly is going on. Inspection of the instance of the class shows that internally it holds the correct context page in the internal variable called contextPath and also internal variable called relativeURI holds proper URI with stripped of context path, however call to getContextPath() returns wrong value.
Having stated the above, there are 2 possible solutions I can see right now:

  • make the trimming of the context path configurable (so it can be enabled when deep context paths are not used)
  • change mapping for the imaging to something else then ".imaging" on weblogic.

Will also try to test on the latest and greatest weblogic version to see if the issue got fixed in the mean time or not.

Generated at Mon Feb 12 10:24:39 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.