dli-generate-synthetic-syslogs
Pipeline: dli-generate-synthetic-syslogs
| @c:new-block
## Create a persistent stream for raw logs, with a short retention policy.
## This is to inspect logs in real time
--> @dm:create-persistent-stream
name = "dli-synthetic-logs-raw" &
retention_days = 2
--> @dm:create-persistent-stream
name = "dli-log-stats" &
retention_days = 90
--> @c:new-block
## Load dataset from Object Store and keep in memory
--> @dm:recall
name = "synthetic_syslogs_dataset"
--> @dm:save
name = "temp-syslogs-dataset"
## Repeat random generation of logs once every 60 seconds
--> @c:timed-loop
interval = 60
--> @dm:recall
name = "temp-syslogs-dataset"
## Randomly select 5% of the logs (dataset by default has 10,000 logs)
--> @dm:sample
n = 0.05
--> @dm:eval
timestamp = "utcnow().isoformat()"
## also copy timestamp into rda_gw_timestamp which is usually inserted by RDA Event Gateway
--> @dm:map
to = "rda_gw_timestamp" &
from = "timestamp"
--> @rn:write-stream
name = "dli-synthetic-logs-raw"
--> @rn:write-stats-to-stream
name = "dli-log-stats" &
groupby = "device" &
mode = "ingested"
|
Extensions used in this Pipeline
Source Name |
Extension Type |
rn |
rn |
Artifacts used in this Pipeline
Artifact Type |
Artifact Name |
Access |
dataset |
synthetic_syslogs_dataset |
read |
rda-network-stream |
dli-synthetic-logs-raw |
write |
rda-network-stream |
dli-log-stats |
write |
Bots used in this Pipeline
@c:new-block @dm:create-persistent-stream @dm:recall @dm:save @c:timed-loop @dm:sample @dm:eval @dm:map @rn:write-stream @rn:write-stats-to-stream