[GLASSFISH-16294] PostConstruct called twice for web service Created: 31/Mar/11 Updated: 14/Feb/13
|Remaining Estimate:||Not Specified|
|Time Spent:||Not Specified|
|Original Estimate:||Not Specified|
GlassFish 3.1, Windows Vista
Simple annotated web service with public constructor, private @PostConstruct and @PreDestroy methods, and a single web service method.
INFO: WEB0671: Loading application [PostConstructIssue] at [/PostConstructIssue]
INFO: Generating code...
INFO: Compiling code...
INFO: Invoking wsimport with http://localhost:8080/PostConstructIssue/MyWebServiceService?WSDL
Example Maven project attached.
Aside from the double-call to the @PostConstruct method, I notice each webservice method call results in a new service object being created. This is different from GlassFish 2.1 behaviour - is it expected, and if so, is the old behaviour configurable?
|Comment by dmitriy.balakin [ 28/Dec/12 ]|
Glassfish 126.96.36.199, bug is still there.
|Comment by Romich [ 14/Feb/13 ]|
The same problem occurs even if CDI used and WebService marked with javax.enterprise.context.ApplicationScoped annotation.
It is expected the only bean instance is created for application.
Any news about this issue?