Hi Frds,
I am using your readymade stateful and stateless sesion
bean application but it has some problem which i have occured for last 3
days.
1) When i execute the application then i have message in console "
init:
undeploy-clean:
deps-clean:
Deleting directory C:\Downloads\Sful\build
Deleting directory C:\Downloads\Sful\dist
clean:
init:
deps-jar:
Created dir: C:\Downloads\Sful\build\classes
Copying 6 files to C:\Downloads\Sful\build\classes\META-INF
Created dir: C:\Downloads\Sful\build\empty
Compiling 4 source files to C:\Downloads\Sful\build\classes
Copying 2 files to C:\Downloads\Sful\build\classes
compile:
library-inclusion-in-archive:
Created dir: C:\Downloads\Sful\dist
Building jar: C:\Downloads\Sful\dist\Sful.jar
dist:
BUILD SUCCESSFUL (total time: 0 seconds)
2) But when i run Build the program then i have problem
init:
deps-jar:
compile:
library-inclusion-in-archive:
Building jar: C:\Downloads\Sful\dist\Sful.jar
dist-directory-deploy:
debug:
Undeploying ...
Initializing...
Distributing C:\Downloads\Sful\dist\Sful.jar to [GlassFish Server 3]
Initializing...
connect-debugger:
Non-existing path "C:\Downloads\Sful\${web.docbase.dir}" provided.
C:\Downloads\Sful\nbproject\build-impl.xml:606: The following error
occurred while executing this line:
C:\Downloads\Sful\nbproject\build-impl.xml:609:
org.netbeans.api.debugger.jpda.DebuggerStartException: handshake failed
- connection prematurally closed
at
org.netbeans.modules.debugger.jpda.JPDADebuggerImpl.waitRunning(JPDADebuggerImpl.java:374)
at
org.netbeans.modules.debugger.jpda.JPDADebuggerImpl.waitRunning(JPDADebuggerImpl.java:356)
at
org.netbeans.api.debugger.jpda.JPDADebugger.attach(JPDADebugger.java:295)
at
org.netbeans.modules.debugger.jpda.ant.JPDAConnect$1.run(JPDAConnect.java:226)
at
org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1957)
Caused by: java.io.IOException: handshake failed - connection
prematurally closed
at
com.sun.tools.jdi.SocketTransportService.handshake(SocketTransportService.java:118)
at
com.sun.tools.jdi.SocketTransportService.attach(SocketTransportService.java:214)
at
com.sun.tools.jdi.GenericAttachingConnector.attach(GenericAttachingConnector.java:98)
at
com.sun.tools.jdi.SocketAttachingConnector.attach(SocketAttachingConnector.java:72)
at
org.netbeans.api.debugger.jpda.AttachingDICookie.getVirtualMachine(AttachingDICookie.java:223)
at
org.netbeans.modules.debugger.jpda.actions.StartActionProvider.doStartDebugger(StartActionProvider.java:184)
at
org.netbeans.modules.debugger.jpda.actions.StartActionProvider.access$200(StartActionProvider.java:80)
at
org.netbeans.modules.debugger.jpda.actions.StartActionProvider$1.run(StartActionProvider.java:161)
... 2 more
BUILD FAILED (total time: 1 second)
3) when client file run ...
init:
deps-jar:
compile-single:
run-main:
javax.naming.NoInitialContextException: Need to specify class name in
environment or system property, or as an applet parameter, or in an
application resource file: java.naming.factory.initial
at
javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:645)
at
javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
at
javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:325)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at ejb30.SfulJavaClient.main(SfulJavaClient.java:12)
BUILD SUCCESSFUL (total time: 0 seconds)
I use the link
http://glassfish.java.net/javaee5/ejb/examples/Sful.html
problem occures.
so please help me i am new in ejb 3.0.
I hope you will give me reply very soon.