Resolution: Works as designed
Affects Version/s: 1.12
Fix Version/s: 1.17
ubuntu 11.10 3.0.0-15-server x86_64
Glassfish 3.1.2 with Jersey 1.12
When you deploy multiple webapps using jersey and CDI you get the attached exception dump when you access in specific situations. Any jersey based webapp having a beans.xml seems to be affected. Initially I thought this was related to virtual servers, but works if not using virtual servers.
The problem occurs when you have multiple webapps deployed using CDI, the problem happens for the second and subsequent webapps accessed after deployment, the first one accessed works as expected.
The behaviour differs slightly depending upon your use of virtual servers.
If you have multiple virtual servers and place each webapp into its a different virtual server, then whichever is "run" first works, the others fail with the attached exception. Redeploying makes no difference once the issue has been encountered, Restarting glassfish resets things and again the first to be run works ok, all others fail.
If you use a single virtual machine the issue is slightly different. With a fresh glassfish setup, you can install multiple webapps into the same virtual server without problem and all work as expected. However once you restart glassfish, only the first to be accessed works without the exception. Again, redeploying the "failed" apps doesn't solve the problem, the only way to resolve the issue is to undeploy all webapps and redeploy one by one.