From efc6b010a31af6b4577a6286e6b9b364bbd2cfa6 Mon Sep 17 00:00:00 2001 From: WSO2 Builder Date: Tue, 6 Aug 2019 16:46:07 +0000 Subject: [PATCH] [WSO2-Release] [Release 3.1.1] update documentation for release 3.1.1 --- README.md | 4 +- docs/api/3.1.1.md | 104 +++++++++++++++++++++++++++++++++++++++++++++ docs/api/latest.md | 41 ++++++++++-------- docs/index.md | 4 +- mkdocs.yml | 67 +++++++++++++++-------------- 5 files changed, 166 insertions(+), 54 deletions(-) create mode 100644 docs/api/3.1.1.md diff --git a/README.md b/README.md index 9b2050b..b2e9152 100644 --- a/README.md +++ b/README.md @@ -19,11 +19,11 @@ For information on Siddhi and i ## Latest API Docs -Latest API Docs is 3.1.0. +Latest API Docs is 3.1.1. ## Features -* redis *(Store)*

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

+* redis *(Store)*

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

## Dependencies diff --git a/docs/api/3.1.1.md b/docs/api/3.1.1.md new file mode 100644 index 0000000..6841c5c --- /dev/null +++ b/docs/api/3.1.1.md @@ -0,0 +1,104 @@ +# API Docs - v3.1.1 + +!!! Info "Tested Siddhi Core version: *5.1.2*" + It could also support other Siddhi Core minor versions. + +## Store + +### redis *(Store)* +

+

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

+

+Syntax + +``` +@Store(type="redis", table.name="", cluster.mode="", nodes="", ttl.seconds="", ttl.on.update="", ttl.on.read="") +@PrimaryKey("PRIMARY_KEY") +@Index("INDEX") +``` + +QUERY PARAMETERS + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionDefault ValuePossible Data TypesOptionalDynamic
table.name

The name with which the event table should be persisted in the store. If noname is specified via this parameter, the event table is persisted with the same name as the Siddhi table.

The tale name defined in the siddhi appSTRINGYesNo
cluster.mode

This will decide the redis mode. if this is false, client will connect to a single redis node.

falseBOOLNoNo
nodes

host, port and the password of the node(s).In single node mode node details can be provided as follows- "node='hosts:port@password'"
In clustered mode host and port of all the master nodes should be provided separated by a comma(,). As an example "nodes = 'localhost:30001,localhost:30002'".

localhost:6379@rootSTRINGYesNo
ttl.seconds

Time to live in seconds for each record

-1LONGYesNo
ttl.on.update

Set ttl on row update

falseBOOLYesNo
ttl.on.read

Set ttl on read rows

falseBOOLYesNo
+ +Examples +EXAMPLE 1 +``` +@store(type='redis',nodes='localhost:6379@root',table.name='fooTable',cluster.mode=false)define table fooTable(time long, date String) +``` +

+

Above example will create a redis table with the name fooTable and work on asingle redis node.

+

+EXAMPLE 2 +``` +@Store(type='redis', table.name='SweetProductionTable', nodes='localhost:30001,localhost:30002,localhost:30003', cluster.mode='true') +@primaryKey('symbol') +@index('price') +define table SweetProductionTable (symbol string, price float, volume long); +``` +

+

Above example demonstrate how to use the redis extension to connect in to redis cluster. Please note that, as nodes all the master node's host and port should be provided in order to work correctly. In clustered node password will not besupported

+

+EXAMPLE 3 +``` +@store(type='redis',nodes='localhost:6379@root',table.name='fooTable', ttl.seconds='30', ttl.onUpdate='true', ttl.onRead='true')define table fooTable(time long, date String) +``` +

+

Above example will create a redis table with the name fooTable and work on asingle redis node. All rows inserted, updated or read will have its ttl set to 30 seconds

+

diff --git a/docs/api/latest.md b/docs/api/latest.md index c8e130e..6841c5c 100644 --- a/docs/api/latest.md +++ b/docs/api/latest.md @@ -1,12 +1,16 @@ -# API Docs - v3.1.0 +# API Docs - v3.1.1 -## Store - -### redis *(Store)* +!!! Info "Tested Siddhi Core version: *5.1.2*" + It could also support other Siddhi Core minor versions. -

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

+## Store +### redis *(Store)* +

+

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

+

Syntax + ``` @Store(type="redis", table.name="", cluster.mode="", nodes="", ttl.seconds="", ttl.on.update="", ttl.on.read="") @PrimaryKey("PRIMARY_KEY") @@ -25,7 +29,7 @@ table.name - The name with which the event table should be persisted in the store. If noname is specified via this parameter, the event table is persisted with the same name as the Siddhi table. +

The name with which the event table should be persisted in the store. If noname is specified via this parameter, the event table is persisted with the same name as the Siddhi table.

The tale name defined in the siddhi app STRING Yes @@ -33,7 +37,7 @@ cluster.mode - This will decide the redis mode. if this is false, client will connect to a single redis node. +

This will decide the redis mode. if this is false, client will connect to a single redis node.

false BOOL No @@ -41,7 +45,7 @@ nodes - host, port and the password of the node(s).In single node mode node details can be provided as follows- "node='hosts:port@password'"
In clustered mode host and port of all the master nodes should be provided separated by a comma(,). As an example "nodes = 'localhost:30001,localhost:30002'". +

host, port and the password of the node(s).In single node mode node details can be provided as follows- "node='hosts:port@password'"
In clustered mode host and port of all the master nodes should be provided separated by a comma(,). As an example "nodes = 'localhost:30001,localhost:30002'".

localhost:6379@root STRING Yes @@ -49,7 +53,7 @@ ttl.seconds - Time to live in seconds for each record +

Time to live in seconds for each record

-1 LONG Yes @@ -57,7 +61,7 @@ ttl.on.update - Set ttl on row update +

Set ttl on row update

false BOOL Yes @@ -65,7 +69,7 @@ ttl.on.read - Set ttl on read rows +

Set ttl on read rows

false BOOL Yes @@ -78,8 +82,9 @@ ``` @store(type='redis',nodes='localhost:6379@root',table.name='fooTable',cluster.mode=false)define table fooTable(time long, date String) ``` -

Above example will create a redis table with the name fooTable and work on asingle redis node.

- +

+

Above example will create a redis table with the name fooTable and work on asingle redis node.

+

EXAMPLE 2 ``` @Store(type='redis', table.name='SweetProductionTable', nodes='localhost:30001,localhost:30002,localhost:30003', cluster.mode='true') @@ -87,11 +92,13 @@ @index('price') define table SweetProductionTable (symbol string, price float, volume long); ``` -

Above example demonstrate how to use the redis extension to connect in to redis cluster. Please note that, as nodes all the master node's host and port should be provided in order to work correctly. In clustered node password will not besupported

- +

+

Above example demonstrate how to use the redis extension to connect in to redis cluster. Please note that, as nodes all the master node's host and port should be provided in order to work correctly. In clustered node password will not besupported

+

EXAMPLE 3 ``` @store(type='redis',nodes='localhost:6379@root',table.name='fooTable', ttl.seconds='30', ttl.onUpdate='true', ttl.onRead='true')define table fooTable(time long, date String) ``` -

Above example will create a redis table with the name fooTable and work on asingle redis node. All rows inserted, updated or read will have its ttl set to 30 seconds

- +

+

Above example will create a redis table with the name fooTable and work on asingle redis node. All rows inserted, updated or read will have its ttl set to 30 seconds

+

diff --git a/docs/index.md b/docs/index.md index 9b2050b..b2e9152 100644 --- a/docs/index.md +++ b/docs/index.md @@ -19,11 +19,11 @@ For information on Siddhi and i ## Latest API Docs -Latest API Docs is 3.1.0. +Latest API Docs is 3.1.1. ## Features -* redis *(Store)*

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

+* redis *(Store)*

This extension assigns data source and connection instructions to event tables. It also implements read write operations on connected datasource. This extension only can be used to read the data which persisted using the same extension since unique implementation has been used to map the relational data in to redis's key and value representation

## Dependencies diff --git a/mkdocs.yml b/mkdocs.yml index 3c7d318..d5ddff0 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -12,42 +12,43 @@ theme: primary: teal accent: teal extra_css: - - assets/stylesheets/extra.css +- assets/stylesheets/extra.css extra_javascript: - - assets/javascripts/extra.js +- assets/javascripts/extra.js extra: social: - - type: github - link: https://github.com/siddhi-io/siddhi - - type: medium - link: https://medium.com/siddhi-io - - type: twitter - link: https://twitter.com/siddhi_io - - type: linkedin - link: https://www.linkedin.com/groups/13553064 + - type: github + link: https://github.com/siddhi-io/siddhi + - type: medium + link: https://medium.com/siddhi-io + - type: twitter + link: https://twitter.com/siddhi_io + - type: linkedin + link: https://www.linkedin.com/groups/13553064 google_analytics: - - UA-103065-28 - - auto +- UA-103065-28 +- auto markdown_extensions: - - markdown.extensions.admonition +- markdown.extensions.admonition pages: - - Information: index.md - - API Docs: - - latest: api/latest.md - - 3.1.0: api/3.1.0.md - - 3.0.0: api/3.0.0.md - - 2.1.0: api/2.1.0.md - - 2.0.1: api/2.0.1.md - - 2.0.0: api/2.0.0.md - - 1.0.11: api/1.0.11.md - - 1.0.10: api/1.0.10.md - - 1.0.9: api/1.0.9.md - - 1.0.8: api/1.0.8.md - - 1.0.7: api/1.0.7.md - - 1.0.6: api/1.0.6.md - - 1.0.5: api/1.0.5.md - - 1.0.4: api/1.0.4.md - - 1.0.3: api/1.0.3.md - - 1.0.2: api/1.0.2.md - - 1.0.1: api/1.0.1.md - - License: license.md +- Information: index.md +- API Docs: + - latest: api/latest.md + - 3.1.1: api/3.1.1.md + - 3.1.0: api/3.1.0.md + - 3.0.0: api/3.0.0.md + - 2.1.0: api/2.1.0.md + - 2.0.1: api/2.0.1.md + - 2.0.0: api/2.0.0.md + - 1.0.11: api/1.0.11.md + - 1.0.10: api/1.0.10.md + - 1.0.9: api/1.0.9.md + - 1.0.8: api/1.0.8.md + - 1.0.7: api/1.0.7.md + - 1.0.6: api/1.0.6.md + - 1.0.5: api/1.0.5.md + - 1.0.4: api/1.0.4.md + - 1.0.3: api/1.0.3.md + - 1.0.2: api/1.0.2.md + - 1.0.1: api/1.0.1.md +- License: license.md