I have a web application (WAR file) which uses jersey jars.Now when i am trying to deploy this i am getting class cast exception(Some bootstrap servlet uses jersey)..On anal
Get the weblogic.xml
generated on the fly by WebLogic and modify it to add:
<container-descriptor>
<prefer-web-inf-classes>true</prefer-web-inf-classes>
</container-descriptor>
Now make sure to have this weblogic.xml in your war file and redeploy the application.
Setting prefer-web-inf-classes to true will give preference to the classes present in the application's WEB-INF directory.
prefer-web-inf-classes
may not work all the time. If you are using a WebLogic version of 10.3.4+ then use remove prefer-web-inf-classes setting and use prefer-application-packages instead. Also go through this video on how classloading in WebLogic works.