2013-05-17

Hi I'm working on a application that has a weird problem. The application works fine in both local tomcat and remote tomcat deployments, but on certain modules the url context changes.

Here's one of the examples:

first I have this in my Web.xml as to eliminate doubt:

I have the following form:

which is called by javascript. Notice I'm using Thymeleaf tags. Usually this fixes the url so it is within the application's context.

Now in my local instance this translates to localhost:8080/customer/relations/add which goes to my spring mvc controller just fine. However in the remote tomcat deployment where the application is under context testapp it should translate to XX.XX.XXX.XX:8080/testapp/customer/relations/add. This is not the case, it insteads does this: XX.XX.XXX.XX:8080/customer/relations/add, which then yields a 404 with message The requested resource (/customer/account-relations/add/) is not available.. The rest of the application works fine on the remote deployment server and stays within context.

Upon inspection, when I open the page and examine the source it is defined correctly as:

However when the action occurs it goes into what I just explained.

I have no way to check the application log, and I am unsure if this is a tomcat issue, a spring security issue or a thymeleaf issue.

Any clues as to how I may solve this? Otherwise I would have to hold out on getting access to the remote logs and that would take me a bit of time to get the credentials to access them.

Show more