Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
  • 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

axis simple examples error

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

I would appreciate if any one could help me solve this problem. I am trying to implement a simple webserive which is listed on axis user guide web page. I have copied the Calculator.jws to c:\Program Files\Tomcat 5.5\Webapps\axis folder.

I have the following jar files in my class path:

axis.jar,mail.jar,saaj.jar,log4j-1.2.8.jar,wsdl-1.5.1.jar,activation.jar,commons-logging-1.0.4.jar,jaxrpc.jar,commons-discovery-0.2.jar.

when I access http://localhost:8080/axis/Calculator.jws I read there is a webservice here message.

When I access http://localhost:8080/axis/Calculator.jws?wsdl I read the following error message:
---------------------------------------------------------------------------
Sorry, something seems to have gone wrong... here are the details:

Fault - Error while compiling: C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\axis\WEB-INF\jwsClasses\calculator.java
AxisFault
faultCode: {http://xml.apache.org/axis/}Server.compileError
faultSubcode:
faultString: Error while compiling: C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\axis\WEB-INF\jwsClasses\calculator.java
faultActor:
faultNode:
faultDetail:
{}Errors:Error compiling C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\axis\WEB-INF\jwsClasses\calculator.java:
Line 1, column 7: class Calculator is public, should be declared in a file named Calculator.java
Line 0, column 0:
1 error
---------------------------------------------------------------------------

Please help me solving this problem. Also could please guide me how to execute the client for invoking this service ?

Thanks and Regards

Ayub
 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Guess the problem in your file name

Check the file name

calculator.java

or

Calculator.java.
 
Ayub ali khan
Ranch Hand
Posts: 399
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Uma,

Thanks for the inputs. Now my webservice is deployed successfully. When I execute the following command at c:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\axis\web-inf\classes\samples\userguide\example2> java CalcClient -p8080 add 2 5

I read the below error...

NoClassDefFoundError:CalcClient(wrong name:samples/userguide/example2/CalcClient)

please how to solve this issue ?

Thanks Ayub
 
This. Exactly this. This is what my therapist has been talking about. And now with a tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic