Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

XmlRpcClientLite is used in callLocalServerManager to execute a method of a remote local XMLRPC server. The server port, credentials and the remote method name and its parameter list are given as parameters to callLocalServerManager. This method doesn't look like it has anything in common with the ExecServer class and possibly could be completely separated. Also, I can't find anywhere is the OODT code that the callLocalServerManager method be called.

XmlRpcServer class is created in the constructor of ExecSerer:

Code Block
        // Create the XML-RPC interface to this server.
        xmlrpcServer = new XmlRpcServer();
        xmlrpcServer.addHandler("server", this);

From the comment, probably XMLRPC is used to control ExecServer while it is running, that is call methods of ExecServer.

XmlRpcServer is also used in the control() method, that seems to execute and arbitrary command on the server.

Code Block
    /** Control this server.
     *
     * @param command Command to send to the server.
     * @return Results of <var>command</var>.
     */

    public byte[] control(byte[] command) {
        return xmlrpcServer.execute(new ByteArrayInputStream(command));
    }

What is different from other uses of XmlRpcServer in other parts of OODT is that here it doesn't don't use the WebServer class.

From docs of XmlRpcServer:

A multithreaded, reusable XML-RPC server object. The name may be misleading because this does not open any server sockets. Instead it is fed by passing instances of XmlRpcRequest from a transport.

 

Code Block
Searching 126 files for "apache.xmlrpc."

/home/radu/oodt/commons/src/main/java/org/apache/oodt/commons/ExecServer.java:
   28  import org.apache.oodt.commons.io.Log;
   29  import org.apache.oodt.commons.util.*;
   30: import org.apache.xmlrpc.XmlRpcClientLite;
   31: import org.apache.xmlrpc.XmlRpcServer;
   32  import org.w3c.dom.*;
   33  import org.xml.sax.*;

2 matches in 1 file

...