# yaml-language-server: $schema=http://json-schema.org/draft-07/schema
# SPDX-FileCopyrightText: 2014-2023 Institute for Automation of Complex Power Systems, RWTH Aachen University
# SPDX-License-Identifier: Apache-2.0
---
type: object

properties:

  hugepages:
    type: integer
    default: 100
    title: Number of reserved hugepages
    description: |
      The number of hugepages which will be reservered by the system.

      See: https://www.kernel.org/doc/Documentation/vm/hugetlbpage.txt

      A value of zero will disable the use of huge pages.

  stats:
    type: number
    default: 1.0
    title: Statistics interval
    description: |
      Specifies the rate at which statistics about the active paths will be periodically printed to the screen.

      Setting this value to 5, will print 5 lines per second.

      A line includes information such as:

      - Source and Destination of path
      - Messages received
      - Messages sent
      - Messages dropped

  affinity:
    type: integer
    default: 0
    title: Task/Process affinity mask
    description: |
      Restricts the exeuction of the daemon to certain CPU cores.
      This technique, also called 'pinning', improves the determinism of the server by isolating the daemon processes on exclusive cores.

      A value of `0` will not change the affinity of the process.

  priority:
    type: integer
    default: 0
    description: |
      Adjusts the scheduling priority of the deamon processes.
      By default, the daemon uses a real-time optimized FIFO scheduling algorithm.

      A value of `0` will not change the priority of the process.

  idle_stop:
    type: boolean
    default: true

  uuid:
    type: string
    format: uuid
    title: Super-node UUID
    default: 'randomly generated'
    description: |
      Each VILLASnode instance is identified by a globally unique indentifier / UUID.

      This UUID can be queried by the API.

      If the setting is not provided, a UUID will be generated by hashing the active VILLASnode configuration.
      This ensures that restarting the VILLASnode instance with the identical configuration will yield always the same UUID.