This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

This sample demonstrates the use of the Cassandra data source functionality in WSO2 Enterprise Integrator (WSO2 EI), which you can use to connect to a Cassandra cluster.

Prerequisites

A Cassandra server of version 1.2.x, 2.0 or 3.0 should be already running in the default port. Cassandra version 3.0 is recommended.

Building the sample

The sample data service CassandraSample should be deployed using the instructions in Samples Setup section. Go to Cassandra for details on how to create Cassandra data sources.

Running the sample

The sample can be run using any SOAP client such as the Tryit tool that comes bundled with WSO2 EI.

Service description

The service contains the following operations:

  • "createKS": This creates the Cassandra keyspace required for the sample. This must be called once before running other operations.
  • "createTable": This creates a Cassandra CQL3 table required for the sample. This must be called once after "createKS" is called.
  • "addUser": This operation takes in user details and adds it to Cassandra. Here "ID" is the primary key and it takes in an UUID as the value.
  • "addUser_batch_req": This is the corresponding batch request of "addUser", where it takes in a batch of "addUser" data entries and adds it as a single batch operation.
  • "getUserById": This operation returns the user information when you provide the ID of a specific user.
  • "getUsers": This operation returns information of all the users stored in the Cassandra store.

 

  • No labels