Link to home
Start Free TrialLog in
Avatar of intlgd
intlgd

asked on

Websphere 7 changes order of servlet filter-mapping on deployment

Hello Experts,

I'm new to websphere, but not to Application Servers. I've worked with a number of light weight and full fledged web/app servers and have never seen this kind of strange behavior. It appears that when I deploy my webapp to Websphere it creates a new web.xml and changes the order of my filter-mapping. This creates some strange behavior, as my filters are in a specific order to setup a hibernate session if it has not yet been done before it authenticates the user. I've combed through the files in the Websphere folders and found that the web_merged.xml file matches this new order. This must be an autogenerated file or something. I modified this file and still end up with the same 'wrong' order when I go into the WAS Admin console and look at the module deployment descriptor.

How can I force the correct order or force WAS to use my web.xml. rather than the generated one?

Thanks in advance.
ASKER CERTIFIED SOLUTION
Avatar of intlgd
intlgd

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of HonorGod
I believe that is the appropriate resolution for a couple of reasons.

From my testing, it appears that the contents of the web_merged.xml file is dynamically generated using application annotations whenever the AppServer is started.

So, using this technique basically circumvents the use of the web_merged.xml file.
Avatar of intlgd
intlgd

ASKER

The solution is correct.