Files
cloudkitty/doc/source/user/rating/index.rst
aimbot31 426075d5c0 Updated the documentation's rst markup
Work items:
- "code-block" is now used instead of "code"
- "raw" has been replaced by "console" for code highlighting
- A typo has been fixed in doc/source/user/rating/pyscripts.rst

Change-Id: I065dfd91992520ecc41c2f8fe45026482eddbbfa
2019-08-20 16:16:11 +02:00

2.1 KiB

Rating

CloudKitty is shipped with three rating modules:

  • noop: Rating module for testing purpose (enabled only).
  • hashmap: Default rating module corresponding to usual CloudKitty use cases (disabled by default).
  • pyscripts: Custom rating module allowing you to add your own python scripts (disabled by default).

You can enable or disable each module independently and prioritize one over another at will.

  • Enabled state is represented by a boolean value (True or False).
  • Priority is represented by an integer value.

Note

The module with the biggest priority value will process data first (descending order).

List available modules

List available rating modules:

$ cloudkitty module list
+-----------+---------+----------+
| Module    | Enabled | Priority |
+-----------+---------+----------+
| hashmap   | False   | 1        |
| noop      | True    | 1        |
| pyscripts | False   | 1        |
+-----------+---------+----------+

Enable or disable module

Enable the hashmap rating module:

$ cloudkitty module enable hashmap
+---------+---------+----------+
| Module  | Enabled | Priority |
+---------+---------+----------+
| hashmap | True    | 1        |
+---------+---------+----------+

Disable the pyscripts rating module:

$ cloudkitty module disable pyscripts
+-----------+---------+----------+
| Module    | Enabled | Priority |
+-----------+---------+----------+
| pyscripts | False   | 1        |
+-----------+---------+----------+

Set priority

Set the hashmap rating module priority to 100:

$ cloudkitty module set priority hashmap 100
+---------+---------+----------+
| Module  | Enabled | Priority |
+---------+---------+----------+
| hashmap | True    | 100      |
+---------+---------+----------+

More details

hashmap.rst pyscripts.rst