summaryrefslogtreecommitdiffstats
path: root/src/lib/d2srv/d2_stats.h
blob: 538d5460907c38bf97d3373cb8050d5527f17cf4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Copyright (C) 2021-2024 Internet Systems Consortium, Inc. ("ISC")
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

#ifndef D2_STATS_H
#define D2_STATS_H

#include <list>
#include <string>

namespace isc {
namespace d2 {

/// @brief Statistics Names.
class D2Stats {
public:
    /// @brief Global NCR statistics names.
    ///
    /// - ncr-received
    /// - ncr-invalid
    /// - ncr-error
    /// - queue-mgr-queue-full
    static const std::list<std::string> ncr;

    /// @brief Global DNS update statistics names.
    ///
    /// - update-sent
    /// - update-signed
    /// - update-unsigned
    /// - update-success
    /// - update-timeout
    /// - update-error
    static const std::list<std::string> update;

    /// @brief Key DNS update statistics names.
    ///
    /// - update-sent
    /// - update-success
    /// - update-timeout
    /// - update-error
    static const std::list<std::string> key;

    /// @brief Initialize D2 statistics.
    ///
    /// @note: Add default samples if needed.
    static void init();
};

} // namespace d2
} // namespace isc

#endif // D2_STATS_H