examples.bindings-epochmillis.yaml Maven / Gradle / Ivy
description: examples of bindings that produce long values as epoch millis
scenarios:
default: run type===stdout format=readout
# If you want to control the output, uncomment and edit the statement template below
# and modify the named anchors to suit your output requirements.
#statements:
# example1: "{epochMillis}\n"
bindings:
# All uncommented lines under this are indented, so they become named bindings below
# the entry above
# Normally, the value that you get with a cycle starts at 0.
cycleNum: Identity();
# All uncommented lines under this are indented, so they become named bindings below
# the entry above
# You can offset the start of your millis to some formatted date.
# Notice, that in this case, the result is still in millis since the epoch
randomMillisStartingFeb2018: StartingEpochMillis('2018-02-01 05:00:00');
# You can randomly offset the value by some amount as shown below.
# In this case, the AddHashRange(...) function is internally hashing
# the input value and down-sampling it to the range specified, and then
# adding the resulting value to the input. The range is selected as
# 0,2419200000 because that is how many milliseconds there are in February.
randomMillisWithinFeb2018: AddHashRange(0,2419200000L); StartingEpochMillis('2018-02-01 05:00:00');
© 2015 - 2025 Weber Informatics LLC | Privacy Policy