-
Notifications
You must be signed in to change notification settings - Fork 178
/
namespaces.go
112 lines (100 loc) · 3.37 KB
/
namespaces.go
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
package metrics
// Prometheus metric namespaces
const (
namespaceNetwork = "network"
namespaceStorage = "storage"
namespaceAccess = "access"
namespaceObserver = "observer"
namespaceCollection = "collection"
namespaceConsensus = "consensus"
namespaceVerification = "verification"
namespaceExecution = "execution"
namespaceLoader = "loader"
namespaceStateSync = "state_synchronization"
namespaceExecutionDataSync = "execution_data_sync"
namespaceChainsync = "chainsync"
namespaceFollowerEngine = "follower"
namespaceRestAPI = "access_rest_api"
)
// Network subsystems represent the various layers of networking.
const (
subsystemLibp2p = "libp2p"
subsystemGossip = "gossip"
subsystemEngine = "engine"
subsystemQueue = "queue"
subsystemDHT = "dht"
subsystemBitswap = "bitswap"
subsystemAuth = "authorization"
subsystemRateLimiting = "ratelimit"
subsystemAlsp = "alsp"
subsystemSecurity = "security"
)
// Storage subsystems represent the various components of the storage layer.
const (
subsystemBadger = "badger"
subsystemMempool = "mempool"
subsystemCache = "cache"
)
// Access subsystem
const (
subsystemTransactionTiming = "transaction_timing"
subsystemTransactionSubmission = "transaction_submission"
subsystemConnectionPool = "connection_pool"
subsystemHTTP = "http"
)
// Observer subsystem
const (
subsystemObserverGRPC = "observer_grpc"
)
// Collection subsystem
const (
subsystemProposal = "proposal"
)
// Consensus subsystems represent the different components of the consensus algorithm.
const (
subsystemCompliance = "compliance"
subsystemHotstuff = "hotstuff"
subsystemCruiseCtl = "cruisectl"
subsystemMatchEngine = "match"
)
// Execution Subsystems
const (
subsystemStateStorage = "state_storage"
subsystemMTrie = "mtrie"
subsystemIngestion = "ingestion"
subsystemRuntime = "runtime"
subsystemProvider = "provider"
subsystemBlockDataUploader = "block_data_uploader"
)
// Verification Subsystems
const (
subsystemAssignerEngine = "assigner"
subsystemFetcherEngine = "fetcher"
subsystemRequesterEngine = "requester"
subsystemVerifierEngine = "verifier"
subsystemBlockConsumer = "block_consumer"
subsystemChunkConsumer = "chunk_consumer"
)
// Execution Data Sync Subsystems
const (
subsystemExeDataRequester = "requester"
subsystemExeDataProvider = "provider"
subsystemExeDataPruner = "pruner"
subsystemExecutionDataRequester = "execution_data_requester"
subsystemExecutionStateIndexer = "execution_state_indexer"
subsystemExeDataBlobstore = "blobstore"
)
// module/synchronization core
const (
subsystemSyncCore = "sync_core"
)
// METRIC NAMING GUIDELINES
// Namespace:
// * If it's under a module, use the module name. eg: hotstuff, network, storage, mempool, interpreter, crypto
// * If it's a core metric from a node, use the node type. eg: consensus, verification, access
// Subsystem:
// * Subsystem is optional if the entire namespace is small enough to not be segmented further.
// * Within the component, describe the part or function referred to.
// Constant Labels:
// * node_role: [collection, consensus, execution, verification, access]
// * beta_metric: true