[checkmk-commits] [tribe29/checkmk] 11ed02: Refactor out query_data from cmk/gui/plugins/views...

Lars noreply at github.com
Tue Jun 11 12:20:35 CEST 2019

  Branch: refs/heads/master
  Home:   https://github.com/tribe29/checkmk
  Commit: 11ed026b98d3ae1102af4ef2c8b7865afaaa2853
  Author: Óscar Nájera <oscar.najera at tribe29.com>
  Date:   2019-06-11 (Tue, 11 Jun 2019)

  Changed paths:
    M cmk/gui/plugins/views/__init__.py
    M cmk/gui/plugins/views/bi.py
    M cmk/gui/plugins/views/datasources.py
    M cmk/gui/plugins/views/inventory.py
    M cmk/gui/plugins/views/mkeventd.py
    M cmk/gui/plugins/views/utils.py
    M cmk/gui/views.py

  Log Message:
  Refactor out query_data from cmk/gui/plugins/views/utils.py

- Remove query_data & do_query_data. This functions where isolated from
  RowTable but make more sense as part of the RowTable query
  method. do_query_data is simplified to livestatusquery, and drops any
  formulation of the query language or data post-processing.
- RowTable.query() method had parameter *query*, which is not the full query
  but mostly only some filters or extra instructions. It also gets always
  added to datasource.add_headers for the livestatus query. Thus rename
  to *headers* and update all inherited classes.
- RowTableLivestatus refactored to use the new query method
- ServiceDiscoveryRowTable refactored to follow new use of query
- RowTableCustomers & DataSourceCustomer refactored to follow new use of query
- _do_table_join directly uses RowTable.query instead of query_data
- Graphs query data directly over helper function livestatusquery.


Change-Id: I3a3f884e8efcc16608285d733d1b474dd2daa13c

  Commit: e4fb09a5109ae60ef446b55e0ed753cdc8967446
  Author: Óscar Nájera <oscar.najera at tribe29.com>
  Date:   2019-06-11 (Tue, 11 Jun 2019)

  Changed paths:
    M cmk/gui/plugins/metrics/utils.py
    M cmk/gui/plugins/views/utils.py
    M cmk/gui/valuespec.py
    M tests/unit/cmk/gui/plugins/test_metrics_utils.py

  Log Message:
  Painter for Processed Historic Metrics

- Painter incorporates new concept of dynamic columns.
  Before livestatus query cell parameters can be recovered and RRDcolumns
- Painter incorporates new concept of derive
  This function processes data immediately after Livestatus Datasource. It
  can work with all the rows at once, but only sequentially on the Cells.
- Derive function hashes Cell parameters to identify processed columns at
  later stages
- New ValueSpec MetricName. A DropdownChoice that gathers all known metrics
  in our system. For user then to pick one without having typos. Metrics
  not declared in our metric system can then unfortunately not be used at
  the moment.
- Reverse metric_id translation. Go from canonical metric name to metric
  name used in the RRD archives. Works very well except for fs_used, which
  in the archives corresponds to mountpoints and the metric system
  translation use a regex in this case.


Change-Id: Ib4c44313fea2d4c332585d60418b08de5ca4181e

Compare: https://github.com/tribe29/checkmk/compare/e4e60e24b684...e4fb09a5109a

More information about the checkmk-commits mailing list