|Anonymous | Login | Signup for a new account||04-17-2021 03:30 PDT|
|Main | My View | View Issues | Change Log | Docs|
|Viewing Issue Simple Details [ Jump to Notes ]||[ View Advanced ] [ Issue History ] [ Print ]|
|ID||Category||Severity||Reproducibility||Date Submitted||Last Update|
|0003543||[Resin]||major||always||06-01-09 22:01||06-04-09 15:30|
|Summary||0003543: Hessian @ApplicationScoped Servelet-Mapping Class created multiple times.|
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">
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 [^]
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
Code to demonstrate this is here:
This is a bug, right?
|06-01-09 22:01||skot||New Issue|
|06-01-09 23:58||voodude||Issue Monitored: voodude|
|06-04-09 15:30||ferg||Note Added: 0004059|
|06-04-09 15:30||ferg||Assigned To||=> ferg|
|06-04-09 15:30||ferg||Status||new => closed|
|06-04-09 15:30||ferg||Resolution||open => fixed|
|06-04-09 15:30||ferg||Fixed in Version||=> 4.0.1|
| Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
31 total queries executed.|
27 unique queries executed.