ExpeccoNET RPC Interface
Aus ExpeccoWiki
Some of the operations of expeccoNET can be remote-controlled via an RPC interface. These interfaces allow for external programs to access and even modify artefacts inside expeccoNET. This allows for expeccoNET to be integrated into an existing QM infrastructure.
Currently, interfaces are available for:
XML-RPC
XML-RPC is a lightweight xml-based RPC mechanism, as documented in http://www.xmlrpc.com/spec. XML-RPC uses HTTP as a transport mechanism. If enabled in the system settings, expeccoNET responds to XMLRPC requests at the URL:
<host-and-port>/rpc/xmlrpc
i.e. something like: "http://localhost:8081/rpc/xmlrpc".
Implementations for XML-RPC are very lightweight and available for many programming languages and systems. The protocol is simple enough, to be even used by humans; for example, to invoke the system.versionInfo call as described below, send the following HTTP-POST-request to the service:
<?xml version="1.0"?>
<methodCall>
<methodName>system.listMethods</methodName>
<params></params>
</methodCall>
and get the response:
<?xml version="1.0"?>
<methodResponse>
<params>
<param>
<value>
<array>
<data>
<value>system.getCapabilities</value>
<value>system.listMethods</value>
<value>system.methodHelp</value>
...
</data>
</array>
</value>
</param>
</params>
</methodResponse>
Introspection
The XML-RPC implementation supports the introspection interface:
- struct system.getCapabilities( )
returns a structure containing info about supported RPC-interfaces and protocols
- struct system.versionInfo( )
returns a structure containing version info about the RPC-service itself
- array system.listMethods()
returns a vector of strings, comprising the names of supported RPC-entries.
- array system.methodSignature( string )
returns a vector of strings, comprising the return-type and argument types names of the given RPC-entry.
- string system.methodHelp( string )
returns an informative string, describing the functionality of the given RPC-entry.
use system.getCapabilities and system.listMethods to get up-to-date information on the supported interfaces.