Query on invoking remote java webservices from a Perl Client

From: Asha (s_aasha_at_yahoo.com)
Date: 06/18/04

  • Next message: Paul Marquess: "Re: Berkeley DB perl access"
    Date: 18 Jun 2004 04:54:26 -0700
    
    

    Hi all,
            
    We are working on a Perl client, which should be able to invoke a
    method exposed by remote Java webservice (Eg. JMXConnector) deployed
    in the Weblogic server.

    We have deployed Mbeans (Management Beans) in the Weblogic application
    server. These Mbeans are essentially the Java webservices and these
    are exposed to any client (In our case - Perl) using MX4J/Soap
    Adaptor. This Adaptor uses Apache axis as its SOAP engine. The way of
    communication between a Client and the MX4J/Soap Adaptor is through
    SOAP/HTTP. I.e. The client's request will be in the form of SOAP
    request and the server's response will be in the form of SOAP response
    and these SOAP requests/responses will be transmitted over HTTP as
    they are remotely located.

    Our objective is to invoke a method of these Mbeans (exposed as
    webservices) from a Perl Client. We are using a library called
    SOAP::Lite for Perl, which uses 2 valuable methods 1) uri() 2) proxy()
    to achieve our objective.

    Uri ('uri') - Defines the URI (Universal Resource Identifier) of the
    target method to be called, and returns the same object. This is
    essentially the method's namespace.

    Proxy ('url') - Defines the URL (Universal Resource Locator) of the
    SOAP server, and returns the same object.

    We are trying to invoke the method 'isRegistered ()' exposed by
    JMXConnector Webservice.

     We gave the URL "http://localhost:7001/axis/services/jmxconnector"
    for the Proxy() method and we are able to connect to the WebLogic
    server. We confirmed it from the Log. But, we are unable to invoke the
    method isRegistered () from the JMXConnector Webservice. This might be
    because of the wrong Parameter we have passed for URI (). We searched
    in the net & saw some Perl client examples. In all these, they have
    passed the namespace taken from the WSDL file as the parameter for
    the URI () . We followed the same and we used the namespace
    'http://mx4j.sourceforge.net/remote/soap/1.0' taken from the
    JMXConnector's WSDL file. But, it didn't help us.

    We are getting an error 'Could not find mandatory header connectionId'
    in the Soap Response message.

    The code Snippet is given below:
    ```````````````````````````````
    use SOAP::Lite +trace; #Uses the SOAP::Lite library
    use strict;
    my $soap = new SOAP::Lite ();
    my $service = $soap ->
    uri('http://mx4j.sourceforge.net/remote/soap/1.0')
                        ->
    proxy('http://localhost:7001/axis/services/jmxconnector');
    my $som = $service -> isRegistered();
    my $result = $som-> result();
    print "Is Registered? : $result";

    References:
    ~~~~~~~~~~
    1. http://www.geocities.com/herong_yang/perl/soap_lite.html
    2. http://www.xav.com/perl/site/lib/SOAP/Lite.html
    3. http://secu.zzu.edu.cn/book/Perl/Perl%20Bookshelf%20%5B3rd%20Ed%5D/perlnut/ch14_02.htm

    Any help on this would be greatly appreciated.

    with regards,
    Asha


  • Next message: Paul Marquess: "Re: Berkeley DB perl access"

    Relevant Pages

    • RE: Windows Forms SOAP Server
      ... you have a certain client which use webservice (soap ... message) calls to the remote server to retrieve some info from a 3rd party ... since the ASP.NET webservice is hard to ...
      (microsoft.public.dotnet.framework.windowsforms)
    • Re: XML-string transportieren
      ... > Server ist JAVA, die clients sind C#. Hintergund ist der, dass auf den ... > vom Server zu den Clients und umgekehrt? ... Ich dachte an SOAP, habe aber keine ... Webservice, der per WSDL seine Dienste definiert, eine Proxy-Klasse zu ...
      (microsoft.public.de.german.entwickler.dotnet.csharp)
    • Re: web service client calls from Windows Server 2000
      ... server and it confirms no SOAP going out. ... When does the webservice need to be invoked - the logic, the criteria etc? ...
      (microsoft.public.dotnet.framework.aspnet.webservices)
    • RE: Get an error when post soap message
      ... you have an ASP.NET webservice and a certain client ... app which use XMLHTTP to send SOAP request to the asp.net webservice (in ... we can use some trace tools such as the Soap Tookit's Trace Utility ... | error" if the web service has some parameter. ...
      (microsoft.public.dotnet.framework.aspnet.webservices)
    • Re: Newbie question - how to use Web Service function in Access
      ... I guess it would be much easier if the webservice in question supports HTTP ... VBA must have some functions to help with HTTP requests and responses. ... You'll have to make the SOAP Requests and process the SOAP Responses ... The web services developers have provided me 3 ...
      (microsoft.public.dotnet.framework.aspnet.webservices)