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

Compare with Current View Page History

« Previous Version 4 Next »

The timer transport handler can be used as a periodic data source, which either sends the system time or the time passed since the query started.

Options

  • period: The period in milliseconds
  • timefromstart: If set to true, start from 0. Else start from Jan 1th 1970. (Default: false)

Example

PQL

Example
input = ACCESS({source='Source',
wrapper='GenericPush',
transport='Timer',
protocol='None',
dataHandler='Tuple',
options=[['period', '1000'], ['timefromstart', 'true'],
schema=[['time', 'Timestamp']]
})

or shorter:

input = TIMER({PERIOD = 1000, TIMEFROMSTART = true, SOURCE = 'Source'}) 

CQL

Example
CREATE STREAM source (time Timestamp)
    WRAPPER 'GenericPush'
    PROTOCOL 'None'
    TRANSPORT 'Timer'
    DATAHANDLER 'Tuple'
    OPTIONS ( 'period' '1000')
  • No labels