?
Solved

Websphere 7 changes order of servlet filter-mapping on deployment

Posted on 2010-11-18
3
Medium Priority
?
3,394 Views
Last Modified: 2013-12-10
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.
0
Comment
Question by:intlgd
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Accepted Solution

by:
intlgd earned 0 total points
ID: 34169401
As it turns out I have added an id: id="my_web_app" and a meta data tag: metadata-complete="true" to get it to leave my web.xml as is. This seems to have solved my problem. Will post any additional changes I run into, should I find additional steps necessary.
0
 
LVL 41

Expert Comment

by:HonorGod
ID: 34169564
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.
0
 

Author Closing Comment

by:intlgd
ID: 34203691
The solution is correct.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Verbose logging is used to diagnose garbage collector problems. By default, -verbose:gc output is written to either native_stderr.log or native_stdout.log.   It is also possible to redirect the logs to a user-specified file. This article will de…
Most of the developers using Tomcat find it easy to configure the datasource in Server.xml and use the JNDI name in the code to get the connection.  So the default connection pool using DBCP (or any other framework) is made available and the life go…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question