This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Exception Axis2  RSS feed

 
giuls flower
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello to all,

Do you know why this exception is thrown?



I state that I have no errors at compile time and checking on the Build Path should not have forgotten no library.

Thank you in advance
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Exactly what environment are you trying to host this servlet in?

Note that the servlet container will NOT use the environment path that the compiler uses.

Bill
 
giuls flower
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I explain all. I created a web Service Client with Axis 2 with the follow class:

-HelloWorldStub
-HelloWorldCallBackHandler
-HelloWorldIoException

Now I need use HelloWorldStub to call the webService method : SayHelloWorld, so in another web application I did so:



The exception is generated at the line HelloWorldStub hws = new HelloWorldStub(); but I don't know why.
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course you know why! The exception tells you!

The JVM the servlet container runs in is not able to find the org.apache.etc etc etc class

Did you even read my first message?

Bill
 
giuls flower
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read your answer, but I did not understand why

" JVM runs in the servlet container is not is not able to find the org.apache.etc etc etc class" ..... The exception where it tells me? I do not understand what you mean.

Anyway thanks answers.
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Error 500: javax.servlet.ServletException:
com.ibm.websphere.servlet.error.ServletErrorReport: java.lang.NoClassDefFoundError: org.apache.ws.axis2.StubClass


Means that the reason your statement which tries to create a HelloWorldStub instance fails is that Java can't find the required class files from the axis2 library.

Consult your Websphere documentation for where Websphere looks for library files.

Since you were able to compile, you must have this library where the compiler can find it BUT Websphere has its own rules for looking for classes.

Bill
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!