dims        2003/03/28 09:09:47

  Modified:    java/samples/client DynamicInvoker.java
               java/test/dynamic TestDynamicInvoker.java TestJAXRPCDII.java
  Log:
  Fix for "ant clean all-tests" failure because of XMethods problem AGAIN :-(
  
  Revision  Changes    Path
  1.8       +1 -1      xml-axis/java/samples/client/DynamicInvoker.java
  
  Index: DynamicInvoker.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/samples/client/DynamicInvoker.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- DynamicInvoker.java       28 Oct 2002 22:11:15 -0000      1.7
  +++ DynamicInvoker.java       28 Mar 2003 17:09:46 -0000      1.8
  @@ -190,7 +190,7 @@
           Binding binding = port.getBinding();
           Call call = dpf.createCall(QName.valueOf(portName),
                                      QName.valueOf(operationName));
  -
  +        ((org.apache.axis.client.Call)call).setTimeout(new Integer(15*1000));
           // Output types and names
           Vector outNames = new Vector();
   
  
  
  
  1.10      +5 -0      xml-axis/java/test/dynamic/TestDynamicInvoker.java
  
  Index: TestDynamicInvoker.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/test/dynamic/TestDynamicInvoker.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- TestDynamicInvoker.java   6 Mar 2003 15:25:03 -0000       1.9
  +++ TestDynamicInvoker.java   28 Mar 2003 17:09:47 -0000      1.10
  @@ -59,6 +59,7 @@
   import org.apache.axis.AxisFault;
   import samples.client.DynamicInvoker;
   
  +import java.io.InterruptedIOException;
   import java.net.ConnectException;
   
   public class TestDynamicInvoker extends TestCase {
  @@ -77,6 +78,7 @@
               if (re instanceof AxisFault) {
                   AxisFault fault = (AxisFault) re;
                   if (fault.detail instanceof ConnectException ||
  +                    fault.detail instanceof InterruptedIOException ||
                       (fault.getFaultString().indexOf("Connection timed out") != -1) 
||
                       fault.getFaultCode().getLocalPart().equals("HTTP")) {
                       System.err.println("getTemp HTTP error: " + fault);
  @@ -101,6 +103,7 @@
               if (re instanceof AxisFault) {
                   AxisFault fault = (AxisFault) re;
                   if (fault.detail instanceof ConnectException ||
  +                    fault.detail instanceof InterruptedIOException ||
                       fault.getFaultCode().getLocalPart().equals("HTTP")) {
                       System.err.println("getQuote HTTP error: " + fault);
                       return;
  @@ -124,6 +127,7 @@
               if (re instanceof AxisFault) {
                   AxisFault fault = (AxisFault) re;
                   if (fault.detail instanceof ConnectException ||
  +                    fault.detail instanceof InterruptedIOException ||
                       fault.getFaultCode().getLocalPart().equals("HTTP")) {
                       System.err.println("round4XSD HTTP error: " + fault);
                       return;
  @@ -150,6 +154,7 @@
               if (re instanceof AxisFault) {
                   AxisFault fault = (AxisFault) re;
                   if (fault.detail instanceof ConnectException ||
  +                    fault.detail instanceof InterruptedIOException ||
                       fault.getFaultCode().getLocalPart().equals("HTTP")) {
                       System.err.println("MathService HTTP error: " + fault);
                       return;
  
  
  
  1.2       +8 -7      xml-axis/java/test/dynamic/TestJAXRPCDII.java
  
  Index: TestJAXRPCDII.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/test/dynamic/TestJAXRPCDII.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- TestJAXRPCDII.java        26 Mar 2003 18:04:59 -0000      1.1
  +++ TestJAXRPCDII.java        28 Mar 2003 17:09:47 -0000      1.2
  @@ -56,16 +56,15 @@
   package test.dynamic;
   
   import junit.framework.TestCase;
  -
  -import java.net.ConnectException;
  -import java.net.URL;
  -
   import org.apache.axis.AxisFault;
   
  -import javax.xml.rpc.ServiceFactory;
  -import javax.xml.rpc.Service;
  -import javax.xml.rpc.Call;
   import javax.xml.namespace.QName;
  +import javax.xml.rpc.Call;
  +import javax.xml.rpc.Service;
  +import javax.xml.rpc.ServiceFactory;
  +import java.io.InterruptedIOException;
  +import java.net.ConnectException;
  +import java.net.URL;
   
   public class TestJAXRPCDII extends TestCase {
       public TestJAXRPCDII(String name) {
  @@ -82,12 +81,14 @@
               Call[] calls = service.getCalls(new QName(wsdlNsp,"TemperaturePort"));
               assertTrue(calls != null);
               assertEquals(calls[0].getOperationName().getLocalPart(),"getTemp");
  +            ((org.apache.axis.client.Call)calls[0]).setTimeout(new 
Integer(15*1000));
               Object ret = calls[0].invoke(new Object[]{"02067"});
               System.out.println("Temperature:" + ret);
           }  catch (java.rmi.RemoteException re) {
               if (re instanceof AxisFault) {
                   AxisFault fault = (AxisFault) re;
                   if (fault.detail instanceof ConnectException ||
  +                    fault.detail instanceof InterruptedIOException ||
                       (fault.getFaultString().indexOf("Connection timed out") != -1) 
||
                       fault.getFaultCode().getLocalPart().equals("HTTP")) {
                       System.err.println("getTemp HTTP error: " + fault);
  
  
  

Reply via email to