Versions Compared

Key

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

...

Page properties


Target release3.4.1
Task List

Jira
serverINFN Ticketing System
columnIdsissuekey,summary,issuetype,created,updated,duedate,assignee,reporter,priority,status,resolution
columnskey,summary,type,created,updated,due,assignee,reporter,priority,status,resolution
maximumIssues20
jqlQuerylabels=memcached2influx
serverId8087fedc-8816-3706-9e66-78f987f39e0c

Document status
Status
titleDRAFT
Document ownerAndrea Michelotti 
Designer
DevelopersUnknown User (rsellari) 
Projecthttps://baltig.infn.it/lnf-da-control/memcached2influx.git


...

Create a python application that takes memcached keys and import them into influxdb at a given rate. The configuration file follow !CHAOS specification so that, it can be used as alternative to pure !CHAOS import.

It can be used in our facilities to easy import memcached keys into influxdb so in grafana dashboards.

Deploy

In order to deploy on the CSI 

Influxdb & Grafana

Dafne Dashboards



Code Block
languagejs
titleconfiguration file
{
"dataset":[
{
"name":"e_current", ← name of the variable (in influxdb will appear as measurement)
"type":"double", ← type of the data (valid are: int32|int64|double|float|bool|string|json)
"description":"readout electron current", ← an optional description
"offset":24, ← offset into a binary key
"len":8, ← data size 
"factor":0, ← an optional factor that multiply the data

"lbe":true, ← endianess true: little endian, false: bigendian

"rate":1, ← >0 rate fetch-pushrate (in Hz)
"keybind":"DCTEL002_DYN" ← source memcached key
},
{
"name":"dafne_state",
"type":"json", ← (the data is a utf-8 string, the type of data is implicit once imported in JSON)
"description":"Dafne state",
"offset":0, ← optional in case of json (if not is the offset inside the string)

"variables":["jsonkey1","jsonkey2"], ← optional field that specifies the keys in the json to be pushed (if not specified, all keys must be pushed
"len":256, ← maximum data length
"keybind":"DAFNESTATE_JDAT"
}]
}

...

  • The application will take a configuration file as input that describes the keys to fetch, the rate and describe the data to be imported following the syntax here below
  • The application will take a influxdb server and db name as input and and optional user and password.
  • The application main loop will fetch the specified keys at the specified rate and will push the imported data as descripted described in the configuration file.


Example JSON key

DAFNE INFERRED STATE & CURRENT LIFE TIMEs