Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Section
borderfalse
Column
width15%
Include Page
TUSCANY: Repeating Menu
TUSCANY: Repeating Menu
Include Page
TUSCANY: Java SCA Menu New
TUSCANY: Java SCA Menu New
Column
width85%

<binding.jsonrpc>

The Tuscany Java SCA runtime supports JSON-RPC as a protcol for use with SCA services by using the < binding.jsonrpc> SCDL extension.

This binding has no attributes or elements so to include it on a service simply requires the following SCDL:

Code Block

   <binding.jsonrpc/>

The most common use of JSON-RPC is web browser clients making RPC style calls to serverside SCA services. To facilitate this Apache Tuscany provides a clientside script to initialize the SCA environement within the browser client.

Code Block

    <script type="text/javascript" src="SCA/SCADomain/scaDomain.js" />

Using SCA JSON-RPC services with Dojo

The Dojo toolkit is a popular framework for writing Web 2.0 style browser client applications and Apache Tuscany JSON-RPC services provide built-in support for Dojo RPC. This is done by supporting Simple Method Description (SMD) on all SCA services using the JSON-RPC binding. Similar to ?wsdl for Web services, ?smd for JSON-RPC services returns the SMD for the service and this enables client-side proxy's for the service to be created as simply as the following:

Code Block

  var myService = new dojo.rpc.JsonService("SCA/SCADomain/MyService?smd");

Some examples:

Overview

General description of this extenson

Using The Extension

What does the SCDL look like

Examples

...