The Artima Developer Community
Sponsored Link

Java Answers Forum
Frustating errors while creating java web-service

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
keshari lal

Posts: 3
Nickname: keshari
Registered: May, 2008

Frustating errors while creating java web-service Posted: May 23, 2008 12:01 AM
Reply to this message Reply
Advertisement
Hey All

Me getting a frustating problem while making the webservice using Eclipse, jdk1.6.0_03,and Tomcat-5.0.
The overall scenario is like this.There is a class “WsEpp” of which I have to make webservice.”WsEpp” class is using the object of another class “EppService”, and if certain conditions will be fullfill then “EppService” class will use the object of another class “PrintClass”,which is allready using the object of class “PrintLib”.

“PrintLib” class is a long file and its using many classes which are in supported jar files.
Here is the some part of “PrintLib” where I am facing the problem,

Scenario-1

public epp_Command command_data = new epp_Command();

public PrintLib()
{
System.out.println("CONSTRUCTOR 1");
this.command_data = new epp_Command();
System.out.println("CONSTRUCTOR 2");

}


Here I am using the constructor of the “PrintLib” and “epp_Command” is included into jar files.When “WsEpp” is running as web service then

<faultcode>soapenv:Server.userException</faultcode>
<faultstri ng>java.lang.reflect.InvocationTargetException</faultstring>

occurs as the response of webservice.

Scenario-2

//public epp_Command command_data = new epp_Command();

public PrintLib()
{

System.out.println("CONSTRUCTOR 1");
// this.command_data = new epp_Command();
System.out.println("CONSTRUCTOR 2");


}
When I am commenting the lines as shown in scenarion-2,then the service is running well and printing CONSTRUCTOR 1 and CONSTRUCTOR 2 as given in println command.
And response of webservice gives the desired result.




Scenario-3


public epp_Command command_data = null;

public PrintLib()
{
System.out.println("CONSTRUCTOR 1");
this.command_data = new epp_Command();
System.out.println("CONSTRUCTOR 2");

}

By using scenarion-3 the service is running and printing only CONSTRUCTOR 1 as given in println command.And also

<faultcode>soapenv:Server.userException</faultcode>
<faultstri ng>java.lang.reflect.InvocationTargetException</faultstring>

occurs as the response of webservice.

I am suffering with this problem from last 2 weeks.Kindally help me and provide me the some suggestions and tips.In case of any more requirement I can provid ethe whole codes.

Topic: Java Virtual Machine Launcher:Could not find main class:Program will exit Previous Topic   Next Topic Topic: Batch File: error SETting a variable within a FOR /F loop

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use