Reputation: 405
I have an ejb project which added fully libraries. But when i run ejb-war i got this error in Glassfish server
SEVERE: The return type of the lifecycle method [construcGroup] must be void
SEVERE: Exception while deploying the app [mcGrawLibPro-war]
SEVERE: Exception during lifecycle processing
And ejb-war
In-place deployment at C:\Users\Hung\Documents\NetBeansProjects\mcGrawLibPro\mcGrawLibPro-war\build\web
GlassFish Server, deploy, null, false
C:\Users\Hung\Documents\NetBeansProjects\mcGrawLibPro\mcGrawLibPro-war\nbproject\build-impl.xml:1048: The module has not been deployed.
See the server log for details.
I don't know why GlassFish Server, deploy, null, false because, I took me 3 days to find solution, I already created connection pool with mySQL. I'm using Netbeans 7.4 and Glassfish 4.0. Hope suggestions.
Upvotes: 3
Views: 9357
Reputation: 1108537
GlassFish Server, deploy, null, false
This is just a general summary which indicates that the deployment of the web application has failed due to a bug in the web application itself.
Clues about this bug should be visible in form of an exception before the above line. In your specific case, it's thus the below one:
SEVERE: The return type of the lifecycle method [construcGroup] must be void
This error is recognizable as an unacceptable @PostConstruct
method. One of the requirements of a @PostConstruct
method is that it returns void
(i.e: nothing). According to the error message, you've something like this:
@PostConstruct
public SomeObject construcGroup() {
// ...
return someObject;
}
This is invalid. It should be initializing the bean's properties and returning void
.
private SomeObject someObject;
@PostConstruct
public void construcGroup() {
// ...
this.someObject = someObject;
}
Renaming the method to the canonicalized method name init()
would be nice, too.
Upvotes: 1