# ELT CII SRV (Version 5.0.0)

## Features and Fixes

### OLDB API
(ECII-1154)

We are working on making CII's Python API more pythonic. In the course of that, the OLDB API for
vector-type datapoints no longer requires you to use custom vector classes, but lets you simply work
with python lists.

- If you read a vector-type DataPoint, you receive a python list:
  ```
  val = vector_dp.read_value().get_value()
  isinstance (val, list) # True
  ```

- If you create a vector-type DataPoint using `create_data_point_by_value`, you can pass a python list.
  The type information is inferred from the element type, using the same logic that is used for scalars,
  i.e. str -> STRING, int -> INT64, float -> DOUBLE, bool -> BOOLEAN. If you pass an empty list, we assume "float".
  ```
  val = [1,2,3]
  vector_dp = oldb.create_data_point_by_value (uri, val)
  ```

- Important note: To reduce the porting effort for CII users, we have not yet removed the custom vector classes,
  but they are now simply aliasing python list. This means they do not carry any more CII type info, and behave
  just like a python list, i.e. if you do create_data_point_by_value (elt.oldb.VectorString()), you have factually
  passed an empty list, and as described above, if you pass an empty list, we assume you want "float", and it will
  create for you a datapoint of type "elt.oldb.CiiOldbDataPointVectorDOUBLE".

For completeness, no such simplification was made for matrix-type (2-dim) datapoints.


### OLDB GUI
  - small floating point numbers are shown in scientific notation (ECII-1145)


### CII Logger Names
  (ECII-1011)

  All logger names of CII were changed to be systematic and hierarchical,
  e.g. to enable debug logs for MAL OPCUA, use: `log4cplus.loggers.cii.mal.opcua=DEBUG`

  The list of new names can be found at:
    https://gitlab.eso.org/ecos/eltsw-docs/-/wikis/KnowledgeBase/CII#adjust-cii-log-levels-log


### Log Viewer

  - Fix: user-applied column sizes are not respected, auto-resizes back (ECII-1115)
  - Fix: after pressing the clear button, no logs are displayed any more  (ECII-1130)

#### Column Names
  (ECII-1040)

  We aligned the naming in log gui and log files.

  Whitespace and special chars were removed from all column names:
  (e.g. Log ID -> LogID, Error Date/Time -> ErrorDateTime, etc.)

  The following columns were renamed:
   - Level -> LogType
   - Host -> HostName
   - Code Reference -> Cref

  This change affects code if it uses the log viewer's "visible columns" Qt property.
  It also affects end-users when writing filter expressions into the gui's Query field


### Config(-NG)

  - Fix: file inclusion from absolute path fails (ECII-1060)
  - New save_option: TERSE
  - New directive !cfg.merge allows merging selected instances (ECII-1219)

### Ops-Logs / Telem

  - New methods: (ECII-1215)
    - has_recorder / HasRecorder
    - close_recorder / CloseRecorder
    - record_value / RecordValue
    - record_metadata_kv / RecordMetadataKv

### Tooling

  - cii-services info: shows role and log setup (ECII-1214)


### General

  - internal clean-ups (967, 972, 1132, 1133, 1136, 1154, 1163, 1168, 1180, 1181, 1182, 1200)


## Knowledge Base

  - Getting More Logs [MAL Log] 
    https://gitlab.eso.org/ecos/eltsw-docs/-/wikis/KnowledgeBase/CII#getting-more-logs-mal-log

  - Less or More Logs [OLDB Log]
    https://gitlab.eso.org/ecos/eltsw-docs/-/wikis/KnowledgeBase/CII#less-or-more-logs-oldb-log

  - Adjust CII Log Levels [Log]
    https://gitlab.eso.org/ecos/eltsw-docs/-/wikis/KnowledgeBase/CII#adjust-cii-log-levels-log

