Communication Protocols


In this section the protocols are explained that are used to connect clients with the server. Currently, there are two protocols for this purpose.

XML Protocol

The protocol that is mostly used for the communication between client and server is a protocol based on XML. The idea is quite simple: A message always consists of one line of XML (no linebreaks) that is UTF-8 encoded and terminated by a linebreak. This applies for messages from the client to the server and vice versa.

Besides using this XML protocol in the common way (sending the plain XML string over socket), there is also the possibility to tunnel the XML packets over the XMPP protocol. To use this channel, the XMPP server has to be configured in such a way that there is a defined "external component" with a name and a password. These strings then have to be known to the SQLSpaces configuration (c.f. chapter Configuration). This use case was developed for the Java Open Source XMPP Server Openfire and should be only used in this context, since uses the component library (Whack) that is also used in Openfire. To enable this XMPP tunnel, just modify the configuration accordingly and put the SQLSpaces XMPP libraries in the classpath of the server, i.e. just put them in the lib folder of the server.

The format of the XML documents are defined in an XML schema that can be found here.


JSON Protocol

The default communication protocol from version 4 on is JSON. The protocol structure is equal to the XML protocol structure. Again, if you are not developing your own client, you don't need to care ... The conversion can be seen from the following example:

<write id="9c72bc58-5cf1-40f6-8802-2712821ca322" space="1">
    <field fieldtype="actual" type="string">
      my shiny little tuple content
  "write": {
    "tuple": {
      "fields": [{ 
        "textcontent":"my shiny little tuple content" 


Web Services

An alternative to the XML protocol of the SQLSpaces there is also a web service interface.

The WSDL of each method can be found here:

  • connect.wsdl
  • disconnect.wsdl
  • query.wsdl
  • write.wsdl
  • update.wsdl
  • callback.wsdl
  • get-rights.wsdl
  • "rights.wsdl":
  • "set-version.wsdl":
  • "get-versions.wsdl":
  • "get-all-spaces.wsdl":