Types of settings in BLISS¶
The in-memory data structure store REDIS is used for data in BLISS that requires a persistent representation. REDIS is a key-value pair storage where the keys are strings and the values can have types. The most common types used in BLISS are:
- STRING: Binary data (
bytes
in python). This is mostly used for strings and scalar numbers. - LIST: Ordered, position-indexed, mutable list of STRING values (
list
ofbytes
in python) - SET: Unordered, mutable set (no duplicates) of STRING values (
set
ofbytes
in python) - ZSET: Ordered, mutable set (no duplicates) of STRING values (no native type in python)
- HASH: Mutable mapping of STRING to STRING (
dict
ofbytes
tobytes
in python) - STREAM: Append-only, indexed list of STRING values called events. The stream index or event ID of an event consists of two integers. By default the first integer is the time of publication (milliseconds since epoch) and the second integer is a sequence number (to handle events with the same rounded time since epoch). A STREAM can have a maximal length which makes it a ring buffer.
Single-key REDIS representation¶
These data types in BLISS have a persistent representation in REDIS with one key-value pair:
SimpleSetting
: STRING representation of simple typesstr
,bytes
,int
andfloat
SimpleObjSetting
: STRING representation of any pickleable typeQueueSetting
: LIST representation of alist
of simple valuesQueueObjSetting
: LIST representation of alist
of pickleable valuesHashSetting
: HASH representation of adict
with simple keys and simple valuesStruct
: same asHashSetting
(exposes keys as attributes)HashObjSetting
: HASH representation of adict
with simple keys and pickleable valuesOrderedHashSetting
: ordered version ofHashSetting
OrderedHashObjSetting
: ordered version ofHashObjSetting
Multi-key REDIS representation¶
These data types in BLISS have a persistent representation in REDIS with more than one key-value pair.
ParameterWardrobe
:- db_name (
QueueSetting
): list of instance names - db_name:creation_order: type ZSET in REDIS but no BLISS type
- db_name:default (
OrderedHashSetting
): parameters of the default instance - db_name:instance2 (
OrderedHashSetting
): parameters of the default instance2 - db_name:instance3 (
OrderedHashSetting
): parameters of the default instance3 - …
- db_name (