• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Ron McLeod
  • Tim Cooke
Sheriffs:
  • Devaka Cooray
  • paul wheaton
  • Mark Herschberg
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Frits Walraven
  • Jj Roberts
Bartenders:
  • Carey Brown
  • salvin francis
  • Piet Souris

Head First EJB question

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am new to EJB.
Even after following the steps suggested by Kathy for common CORBA.BAD_OPERATION error, I am still getting javax.naming.NoInitialContextException.
Any help will be appreciated.
 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please provide a short code listing.
Regards,
Chris Lewold
 
Ranch Hand
Posts: 775
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'd guess that you are missing something from your classpath. In your code you've probably got something like:
Context ctx=new InitialContext();
Object obj=ctx.lookup("Advisor");
and you are failing on the lookup. The problem I'm suspecting is that you never really established a connection to the JNDI service of the EJB container.
 
Anu Pardeshi
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess you are right.
As I said, I am new to EJB and started EJB only a week ago.
I have followed all the instructions from "Head First EJB" book.
I was able to install J2EE, use deploytool and deploy the application.
Do I have to install something other than J2SE SDK 1.3.1, J2EE 1.3, RI?
I have set the following environment variables:
PATH ${PATH};c:\j2sdkee1.3.1\bin
CLASSPATH ${J2EE_HOME}\lib\j2ee.jar
JAVA_HOME C:\jdk1.3.1
J2EE_HOME C:\j2sdkee1.3.1
Thanks for your help.
 
Anu Pardeshi
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Got the solution to my problem in deja.com.
Thanks,
Anu
 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Anu Pardeshi,

Bad Form!

Perhaps you could tell us the solution you found.

Thanks,

Mark

PS: The answer you got was here, FWIW:
http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&selm=c3cdbj%24c4o%241%40hood.uits.indiana.edu

PPS: I do agree with the sentiment about the book, and I hope the authors (I believe they read here) aren't offended if I add that I, too, expected an intro app with comments like "Just go with it for now." would Just Work (TM).
[ June 12, 2004: Message edited by: Mark Wuest ]
 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
a small question
what if I want to run the client in another computer
what changes should I do?
 
reply
    Bookmark Topic Watch Topic
  • New Topic