EJB with glassfish 4.1 on a tutorial example : unable to deploy
i have a problem following a tutorial, from the book "Mastering Netbeans".
I'm new to EJB tecnology and to the use of application servers.
the application is a very simple Enterprise application with two modules:
one EjB sub-project (named GreeterEJB)
one client application sub-project (named Greeter)
one class library (named GreeterEJBRemote)
it just prints "Hello James" to the console, calling a single remote method defined in the WelcomeBean class (into GreeterEJB project), from the client application. I don't think there are problems with the code of the application since syntax is ok and all names are correctly resolved.
the problem occurs when i try to build and debug the client application.
It seems that the application is builded and esecuted locally (without using the jar) on the "classes" folder and then the same folder (with its absolute path) is passed to glassfish to be deployed, but the deploy operation needs a jar file.
"the archive classes type was not recognized"
here is the console output when a try to run the client application:
ant -f /Users/james/NetBeansProjects/Greeter -Dnb.internal.action.name=run -Ddirectory.deployment.supported=true -DforceRedeploy=false -Dnb.wait.for.caches=true run
Updating property file: /Users/james/NetBeansProjects/GreeterEJBRemote/build/built-jar.properties
In-place deployment at /Users/james/NetBeansProjects/Greeter/build/classes
GlassFish Server 4.1.1, deploy, null, false
/Users/james/NetBeansProjects/Greeter/nbproject/build-impl.xml:934: The module has not been deployed.
See the server log for details.
BUILD FAILED (total time: 0 seconds)
this is the glassfish log produced by the run application tentative:
Grave: Archive type of /Users/james/NetBeansProjects/Greeter/build/classes was not recognized
this is the build console output for the Eterprise application: