Mantis - Resin
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
3543 | major | always | 06-01-09 22:01 | 06-04-09 15:30 | |
|
|||||
Reporter: | skot | Platform: | |||
Assigned To: | ferg | OS: | |||
Priority: | normal | OS Version: | |||
Status: | closed | Product Version: | 4.0.0 | ||
Product Build: | Resolution: | fixed | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 4.0.1 | ||
|
|||||
Summary: | 0003543: Hessian @ApplicationScoped Servelet-Mapping Class created multiple times. | ||||
Description: |
Creating an @ApplicationScoped class and adding a mapping to expose it via hessian (like below). <servlet-mapping url-pattern="/api/Echo" servlet-class="test.EchoService"> <protocol uri="hessian:"/> </servlet-mapping> Causes multiple instances to be created of the class. Here is a test project that exemplifies the problem:http://scratchmonkey.googlecode.com/svn/resin4/hessian_scopes [^] |
||||
Steps To Reproduce: | |||||
Additional Information: |
Here is the original email sent on May 15th: ScottH and I have spent some time (fortunately, well-spent time in a pub with wifi and a deep reserve of Magners) trying to figure out why one of our @ApplicationScoped objects seems to have several instances in the container. The problem seems to be when you declare the <servlet-mapping> in resin-web.xml. We have a test with two beans, EchoService (@Stateless) and DeeperService (@ApplicationScoped). EchoService calls DeeperService, which logs the object id. When DeeperService has no <servlet-mapping>, calls to EchoService always return the same DeeperService instance. When DeeperService also has a <servlet-mapping>, calls to EchoService return different DeeperService instance. Code to demonstrate this is here: http://scratchmonkey.googlecode.com/svn/resin4/hessian_scopes [^] This is a bug, right? Jeff |
||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|