How to Deploy and Run REST Binding Samples
The ActiveMatrix Service Grid installation includes REST Binding sample programs, which demonstrate the use of the HTTP operations and the Mediation component. These samples are located in the TIBCO_HOME\amx\<version>\samples\rest directory. For step-by-step instructions on these samples, see the "Sample Projects" section in TIBCO ActiveMatrix® Service GridREST Binding Development Guide.
Service Side
The REST Binding includes the following sample programs for the service side:
- Bookstore sample
Implemented in Java. It exposes a potential interaction of a bookstore administrator with the bookstore inventory. The sample includes two HTTP GET operations,
getBookList
andgetBookByTitle
, and one HTTP POST operationaddBook
. - Multiplecomplextypes sample
Demonstrates the use of the Mediation component to expose a WSDL operation with multiple parts of complex type. Your application might need to perform such mediation because the REST Binding only supports WSDL operations with a single part of a complex type.
Reference Side
The REST Binding includes the following sample programs for the reference side:
- Bookstore client sample
This sample is configured with a REST Binding on a reference with XML media-type. It consumes the
bookstore
sample service included in TIBCO ActiveMatrix® Service Grid. - Facebook client sample
This sample is configured with a REST Binding on a reference with Standard JSON as the media-type. It invokes an external Facebook service.
- Pass-Through Mode Sample
This sample is configured with REST Binding on a reference to demonstrate the Pass Through Mode.
Common to Service and Reference Side
- REST Context Sample
This sample demonstrates the usage of context parameters and headers in a REST Binding.
- REST Extended JSON Conversion Sample
This sample demonstrates the XML to JSON conversion of the "string" XSD element on the Reference side (Inbound/Request) and Service side (Outbound/Response).