Documentation ¶
Overview ¶
Package discordreceiver implements a receiver that can be used by the Opentelemetry collector to receive and make statistics of Discord messages
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFactory ¶
NewFactory returns a new factory for the Discord receiver.
Types ¶
type Config ¶
type Config struct { // Token is the Discord bot token. Token string `mapstructure:"token"` // BufferInterval is the interval period to buffer messages from Discord. // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m" and "h", which are // supported by time.ParseDuration(). // Default is "30s". BufferInterval string `mapstructure:"buffer_interval"` // ServerWide is an optional setting to collect statistics from all channels in the server. // If it is false, the receiver collects statistics per channel. // If it is true, the receiver ignores the Channels setting. // Default is false. ServerWide bool `mapstructure:"server_wide,omitempty"` // Channels is an optional setting to collect statistics from specific channels. // If it is empty, the receiver collects statistics from all channels. // The ServerWide setting is true, receiver ignores this setting. Channels []string `mapstructure:"channels,omitempty"` // MetricsBuilderConfig is the configuration for the metrics builder. MetricsBuilderConfig metadata.MetricsBuilderConfig }
Click to show internal directories.
Click to hide internal directories.