• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

appclient gives classnotfoundexception

 
Ben Hsu
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello.

I am trying to get the Advice bean example in chapter 1 of the Head First book running.

I am running Sun's App Server 8.1 2005Q1 on Win2K.

When I try to run the application using appclient I get the following error:

C:\ejb\advice>c:\sun\appserver\bin\appclient -client AdviceAppClient.jar
WARNING: ACC003: Application threw an exception.
java.lang.NoClassDefFoundError: headfirst.AdviceHome
at AdviceClient.class$(AdviceClient.java:16)
at AdviceClient.go(AdviceClient.java:16)
at AdviceClient.main(AdviceClient.java:9)

But I looked at my AdviceAppClient.jar and the headfirst\AdviceHome.class file is in there!


C:\ejb\advice>jar -tvf AdviceAppClient.jar
1417 Mon Dec 19 14:49:52 EST 2005 AdviceClient.class
93 Mon Dec 19 14:49:52 EST 2005 META-INF/sun-j2ee-ri.project
1064 Mon Dec 19 14:49:52 EST 2005 app-client-ic.jar
226 Mon Dec 19 14:49:52 EST 2005 headfirst/Advice.class
1176 Mon Dec 19 14:49:52 EST 2005 headfirst/AdviceBean.class
262 Mon Dec 19 14:49:52 EST 2005 headfirst/AdviceHome.class
1186 Mon Dec 19 14:49:52 EST 2005 ejb-jar-ic.jar
200 Mon Dec 19 14:49:52 EST 2005 META-INF/MANIFEST.MF
477 Mon Dec 19 14:49:52 EST 2005 META-INF/application.xml
354 Mon Dec 19 14:49:52 EST 2005 META-INF/sun-application.xml

Does anybody have any advice? Thank yous in advance.
 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please have a look at this:
http://www.coderanch.com/t/158486/java-EJB-SCBCD/certification/head-first-ejb-pg-client
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic