• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

EJB deployment error

 
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

THANX IN ADVANCE
 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess you need to have tools.jar in your CLASSPATH.
 
vijaya bacina
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
thx a lot... my EJB deployed successfully
but when i try to compile client.. again i am getting error
i am beginner to ejbs and this is my first EJB...


C:\Documents and Settings\Administrator\Desktop\examples>javac HelloClient.java
HelloClient.java:46: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
HelloHome home = (HelloHome)
^
HelloClient.java:46: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
HelloHome home = (HelloHome)
^
HelloClient.java:48: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
obj, HelloHome.class);
^
HelloClient.java:53: cannot resolve symbol
symbol : class Hello
location: class examples.HelloClient
Hello hello = home.create();
^
4 errors

Plz reply if anybody know
thanx
 
Vicky Mohan
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you sure if you have the EJB's visible to the client. My guess is, you do not have the EJB's available for the client ( problem in referring them). Please make sure you have the package structure etc correct.

let us know what happens...
 
vijaya bacina
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
I placed EJBObject-->hello.java ,
EJBHome object---> HelloHome.java
and bean class---> HelloBean.java
and META-INf in examples folder which is on my desktop

and compiled nad packaged them from there

finally i put my client program also in examples folder




how can i make my EJBs visible to client
i even placed the helloworld.jar in classpath also
plz tell me
 
vijaya bacina
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
Actually i am getting errors like this


C:\Documents and Settings\Administrator\Desktop\examples>javac HelloClient.java
HelloClient.java:17: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
HelloHome home = (HelloHome) javax.rmi.PortableRemoteObject.n
arrow(obj, HelloHome.class);
^
HelloClient.java:17: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
HelloHome home = (HelloHome) javax.rmi.PortableRemoteObject.n
arrow(obj, HelloHome.class);
^
HelloClient.java:17: cannot resolve symbol
symbol : class HelloHome
location: class examples.HelloClient
HelloHome home = (HelloHome) javax.rmi.PortableRemoteObject.n
arrow(obj, HelloHome.class);

^
HelloClient.java:19: cannot resolve symbol
symbol : class Hello
location: class examples.HelloClient
Hello hello = home.create();
^
4 errors
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Do one thing create a jar of our EJB files
and put that in classpath

I feel it shd work

Kunal
 
vijaya bacina
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
Thx kunal..my EJB client compiled after placed the jar file in classpath..but not executing


C:\Documents and Settings\Administrator\Desktop\ejbs\examples>java HelloClient
Exception in thread "main" java.lang.NoClassDefFoundError: HelloClient (wrong na
me: examples/HelloClient)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:539)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:12
3)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:251)
at java.net.URLClassLoader.access$100(URLClassLoader.java:55)
at java.net.URLClassLoader$1.run(URLClassLoader.java:194)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)

Plz reply
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
read the J2ee1.4 tutorial on "Getting Started with Enterprise Beans" in this section you will get the answers how to run your Clients
 
WHAT is your favorite color? Blue, no yellow, ahhhhhhh! Tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic