Documentation ¶
Overview ¶
You can use the "packr clean" command to clean up this, and any other packr generated files.
Index ¶
Constants ¶
View Source
const ( MaxTransactionsForAddressResults = 100 MaxApproversResults = 100 MaxTagResults = 100 MaxBundleResults = 100 )
View Source
const ( // MsgTypeSyncStatus is the type of the SyncStatus message. MsgTypeSyncStatus byte = iota // MsgTypeNodeStatus is the type of the NodeStatus message. MsgTypeNodeStatus // MsgTypeTPSMetric is the type of the transactions per second (TPS) metric message. MsgTypeTPSMetric // MsgTypeTipSelMetric is the type of the TipSelMetric message. MsgTypeTipSelMetric // MsgTypeTxZeroValue is the type of the zero value Tx message. MsgTypeTxZeroValue // MsgTypeTxValue is the type of the value Tx message. MsgTypeTxValue // MsgTypeMs is the type of the Ms message. MsgTypeMs // MsgTypePeerMetric is the type of the PeerMetric message. MsgTypePeerMetric // MsgTypeConfirmedMsMetrics is the type of the ConfirmedMsMetrics message. MsgTypeConfirmedMsMetrics // MsgTypeVertex is the type of the Vertex message for the visualizer. MsgTypeVertex // MsgTypeSolidInfo is the type of the SolidInfo message for the visualizer. MsgTypeSolidInfo // MsgTypeConfirmedInfo is the type of the ConfirmedInfo message for the visualizer. MsgTypeConfirmedInfo // MsgTypeMilestoneInfo is the type of the MilestoneInfo message for the visualizer. MsgTypeMilestoneInfo // MsgTypeTipInfo is the type of the TipInfo message for the visualizer. MsgTypeTipInfo // MsgTypeDatabaseSizeMetric is the type of the database Size message for the metrics. MsgTypeDatabaseSizeMetric // MsgTypeDatabaseCleanupEvent is the type of the database cleanup message for the metrics. MsgTypeDatabaseCleanupEvent // MsgTypeSpamMetrics is the type of the SpamMetric message. MsgTypeSpamMetrics // MsgTypeAvgSpamMetrics is the type of the AvgSpamMetric message. MsgTypeAvgSpamMetrics )
View Source
const ( WebsocketCmdRegister = 0 WebsocketCmdUnregister = 1 )
View Source
const (
VisualizerIdLength = 7
)
Variables ¶
View Source
var ( // ErrInvalidParameter defines the invalid parameter error. ErrInvalidParameter = errors.New("invalid parameter") // ErrInternalError defines the internal error. ErrInternalError = errors.New("internal error") // ErrNotFound defines the not found error. ErrNotFound = errors.New("not found") // ErrForbidden defines the forbidden error. ErrForbidden = errors.New("forbidden") )
View Source
var (
PLUGIN = node.NewPlugin("Dashboard", node.Enabled, configure, run)
)
Functions ¶
This section is empty.
Types ¶
type Cache ¶ added in v0.5.3
type Cache struct {
Size int `json:"size"`
}
Cache represents metrics about a cache.
type CachesMetric ¶ added in v0.5.3
type CachesMetric struct { RequestQueue Cache `json:"request_queue"` Approvers Cache `json:"approvers"` Bundles Cache `json:"bundles"` Milestones Cache `json:"milestones"` SpentAddresses Cache `json:"spent_addresses"` Transactions Cache `json:"transactions"` IncomingTransactionWorkUnits Cache `json:"incoming_transaction_work_units"` }
CachesMetric represents cache metrics.
type DBSizeMetric ¶ added in v0.5.3
DBSizeMetric represents database size metrics.
func (*DBSizeMetric) MarshalJSON ¶ added in v0.5.3
func (s *DBSizeMetric) MarshalJSON() ([]byte, error)
type ExplorerAddress ¶
type ExplorerAddress struct { Balance uint64 `json:"balance"` Txs []*ExplorerTx `json:"txs"` Spent bool `json:"spent"` SpentEnabled bool `json:"spent_enabled"` }
type ExplorerTag ¶
type ExplorerTag struct {
Txs []*ExplorerTx `json:"txs"`
}
type ExplorerTx ¶
type ExplorerTx struct { Hash trinary.Hash `json:"hash"` SignatureMessageFragment trinary.Trytes `json:"signature_message_fragment"` Address trinary.Hash `json:"address"` Value int64 `json:"value"` ObsoleteTag trinary.Trytes `json:"obsolete_tag"` Timestamp uint64 `json:"timestamp"` CurrentIndex uint64 `json:"current_index"` LastIndex uint64 `json:"last_index"` Bundle trinary.Hash `json:"bundle"` Trunk trinary.Hash `json:"trunk"` Branch trinary.Hash `json:"branch"` Tag trinary.Trytes `json:"tag"` Nonce trinary.Trytes `json:"nonce"` AttachmentTimestamp int64 `json:"attachment_timestamp"` AttachmentTimestampLowerBound int64 `json:"attachment_timestamp_lower_bound"` AttachmentTimestampUpperBound int64 `json:"attachment_timestamp_upper_bound"` Confirmed struct { State bool `json:"state"` Conflicting bool `json:"conflicting"` Milestone milestone.Index `json:"milestone_index"` } `json:"confirmed"` Approvers []string `json:"approvers"` Solid bool `json:"solid"` MWM int `json:"mwm"` Previous trinary.Hash `json:"previous"` Next trinary.Hash `json:"next"` BundleComplete bool `json:"bundle_complete"` IsMilestone bool `json:"is_milestone"` MilestoneIndex milestone.Index `json:"milestone_index"` }
type LivefeedMilestone ¶ added in v0.5.3
LivefeedMilestone represents a milestone for the livefeed.
type LivefeedTransaction ¶ added in v0.5.3
LivefeedTransaction represents a transaction for the livefeed.
type MemMetrics ¶ added in v0.5.3
type MemMetrics struct { Sys uint64 `json:"sys"` HeapSys uint64 `json:"heap_sys"` HeapInuse uint64 `json:"heap_inuse"` HeapIdle uint64 `json:"heap_idle"` HeapReleased uint64 `json:"heap_released"` HeapObjects uint64 `json:"heap_objects"` MSpanInuse uint64 `json:"m_span_inuse"` MCacheInuse uint64 `json:"m_cache_inuse"` StackSys uint64 `json:"stack_sys"` NumGC uint32 `json:"num_gc"` LastPauseGC uint64 `json:"last_pause_gc"` }
MemMetrics represents memory metrics.
type Msg ¶ added in v0.5.3
type Msg struct { Type byte `json:"type"` Data interface{} `json:"data"` }
Msg represents a websocket message.
type NodeStatus ¶ added in v0.5.3
type NodeStatus struct { SnapshotIndex milestone.Index `json:"snapshot_index"` PruningIndex milestone.Index `json:"pruning_index"` IsHealthy bool `json:"is_healthy"` Version string `json:"version"` LatestVersion string `json:"latest_version"` Uptime int64 `json:"uptime"` AutopeeringID string `json:"autopeering_id"` NodeAlias string `json:"node_alias"` ConnectedPeersCount int `json:"connected_peers_count"` CurrentRequestedMs milestone.Index `json:"current_requested_ms"` RequestQueueQueued int `json:"request_queue_queued"` RequestQueuePending int `json:"request_queue_pending"` RequestQueueProcessing int `json:"request_queue_processing"` RequestQueueAvgLatency int64 `json:"request_queue_avg_latency"` ServerMetrics *ServerMetrics `json:"server_metrics"` Mem *MemMetrics `json:"mem"` Caches *CachesMetric `json:"caches"` }
NodeStatus represents the node status.
type PeerMetric ¶ added in v0.5.3
type PeerMetric struct { Identity string `json:"identity"` Alias string `json:"alias,omitempty"` OriginAddr string `json:"origin_addr"` ConnectionOrigin peer.ConnectionOrigin `json:"connection_origin"` ProtocolVersion byte `json:"protocol_version"` BytesRead uint64 `json:"bytes_read"` BytesWritten uint64 `json:"bytes_written"` Heartbeat *sting.Heartbeat `json:"heartbeat"` Info *peer.Info `json:"info"` Connected bool `json:"connected"` }
PeerMetric represents metrics of a peer.
type SearchResult ¶
type SearchResult struct { Tx *ExplorerTx `json:"tx"` Tag *ExplorerTag `json:"tag"` Address *ExplorerAddress `json:"address"` Bundles [][]*ExplorerTx `json:"bundles"` Milestone *ExplorerTx `json:"milestone"` }
type ServerMetrics ¶ added in v0.5.3
type ServerMetrics struct { NumberOfAllTransactions uint32 `json:"all_txs"` NumberOfNewTransactions uint32 `json:"new_txs"` NumberOfKnownTransactions uint32 `json:"known_txs"` NumberOfInvalidTransactions uint32 `json:"invalid_txs"` NumberOfInvalidRequests uint32 `json:"invalid_req"` NumberOfStaleTransactions uint32 `json:"stale_txs"` NumberOfReceivedTransactionReq uint32 `json:"rec_tx_req"` NumberOfReceivedMilestoneReq uint32 `json:"rec_ms_req"` NumberOfReceivedHeartbeats uint32 `json:"rec_heartbeat"` NumberOfSentTransactions uint32 `json:"sent_txs"` NumberOfSentTransactionsReq uint32 `json:"sent_tx_req"` NumberOfSentMilestoneReq uint32 `json:"sent_ms_req"` NumberOfSentHeartbeats uint32 `json:"sent_heartbeat"` NumberOfDroppedSentPackets uint32 `json:"dropped_sent_packets"` NumberOfSentSpamTxsCount uint32 `json:"sent_spam_txs"` NumberOfValidatedBundles uint32 `json:"validated_bundles"` NumberOfSeenSpentAddr uint32 `json:"spent_addr"` }
ServerMetrics are global metrics of the server.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.