This documentation is for WSO2 Stream Processor 4.2.0. View documentation for the latest release.

All docs This doc

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Note

You can retrieve the same resultant aggregate value by executing the following cURL command.

Code Block
curl -X POST https://localhost:9443/stores/query -H "content-type: application/json" -u "admin:admin" 
-d '{"appName" : "<<Application Name>>", "query" : "<<query>>" }' -k
  • <<Application Name>> : This defines the application name, e.g., AggregationTest.
  • <<query>>: This defines the query that retrieves the aggregate value.

    Code Block
    titleExample
    from TradeAggregation as a 
        on a.symbol == "FB"
    within "2014-02-15 00:00:00 +05:30", "2014-03-16 00:00:00 +05:30"
    per "days"

For more information, see Managing Stored Data via REST API.

Apart from providing these within and per values as constants in the query itself, the user has the capability of retrieving those values from attributes in the incoming stream. An example is as follows.

...