Skip to content

Siddhi Execution JSON

Jenkins Build Status GitHub Release GitHub Release Date GitHub Open Issues GitHub Last Commit License

The siddhi-execution-json extension is a Siddhi extension that provides capability to retrieve, insert, and modify JSON elements.

For information on Siddhi and it's features refer Siddhi Documentation.

Download

  • Versions 2.x and above with group id io.siddhi.extension.* from here.
  • Versions 1.x and lower with group id org.wso2.extension.siddhi.* from here.

Latest API Docs

Latest API Docs is 2.0.10.

Features

  • group (Aggregate Function)

    This function aggregates the JSON elements and returns a JSON object by adding enclosing.element if it is provided. If enclosing.element is not provided it aggregate the JSON elements returns a JSON array.

  • groupAsObject (Aggregate Function)

    This function aggregates the JSON elements and returns a JSON object by adding enclosing.element if it is provided. If enclosing.element is not provided it aggregate the JSON elements returns a JSON array.

  • getBool (Function)

    Function retrieves the 'boolean' value specified in the given path of the JSON element.

  • getDouble (Function)

    Function retrieves the 'double' value specified in the given path of the JSON element.

  • getFloat (Function)

    Function retrieves the 'float' value specified in the given path of the JSON element.

  • getInt (Function)

    Function retrieves the 'int' value specified in the given path of the JSON element.

  • getLong (Function)

    Function retrieves the 'long' value specified in the given path of the JSON element.

  • getObject (Function)

    Function retrieves the object specified in the given path of the JSON element.

  • getString (Function)

    Function retrieves value specified in the given path of the JSON element as a string.

  • isExists (Function)

    Function checks whether there is a JSON element present in the given path or not.

  • setElement (Function)

    Function sets JSON element into a given JSON at the specific path.

  • toObject (Function)

    Function generate JSON object from the given JSON string.

  • toString (Function)

    Function generates a JSON string corresponding to a given JSON object.

  • tokenize (Stream Processor)

    Stream processor tokenizes the given JSON into to multiple JSON string elements and sends them as separate events.

  • tokenizeAsObject (Stream Processor)

    Stream processor tokenizes the given JSON into to multiple JSON object elements and sends them as separate events.

Dependencies

There are no other dependencies needed for this extension.

Installation

For installing this extension on various siddhi execution environments refer Siddhi documentation section on adding extensions.

Support and Contribution

  • We encourage users to ask questions and get support via StackOverflow, make sure to add the siddhi tag to the issue for better response.

  • If you find any issues related to the extension please report them on the issue tracker.

  • For production support and other contribution related information refer Siddhi Community documentation.