Skip to content

Hatohol server technical information

Kazuhiro Yamato edited this page Jul 4, 2014 · 18 revisions

Software stack of components related to data transfer directly

Classes

FaceRest

A REST interface to get unified data and configure Hatohol itself.

ArmZabbixAPI, ArmNagiosNDOUtils

A component to get monitoring data from monitoring servers such as Zabbix server.

DBAgent

  • A base class to access DBs
  • Actual Subclassess: DBAgentMySQL and DBAgentSQLite3

DBClient

  • The subclasses do the following things
    • Provides C++ like API to access data in DB.
    • manages one or more tables on DB.
    • Convert data format: list or vector <==> ItemTable.

ItemTable and ItemGroup

ItemData

  • A virtual base class to handle various type of value with the same interfaces.
  • Implemented subclasses:
    • ItemInt
    • ItemBool
    • ItemString
    • ItemDouble
    • ItemUint64
  • A ItemData instance has the following information
    • ItemID (can be SYSTEM_ITEM_ID_ANONYMOUS)
    • Data type
    • Null flag
    • Value
    • Used count (derived from UsedCountable class)
  • Cannot modify the value once it is added to ItemGroup because it has ItemData as const. After that ItemData can be used multiple contexts on different threads.
  • An instance is typically wrapped by ItemDataPtr that is a smart pointer for ItemData and increments (decrements) the used count at the constructor (destructor).