Documentation ¶
Index ¶
- Variables
- func NewFxLoggerFactory(fxLF di.FxLoggerFactory, slackClient *Client, lf *log.LoggerFactory) di.FxLoggerFactory
- type Client
- func (s *Client) Errorb(blocks []map[string]any) error
- func (s *Client) Errorf(message string, args ...any) error
- func (s *Client) Infob(blocks []map[string]any) error
- func (s *Client) Infof(message string, args ...any) error
- func (s *Client) Send(channelType WebhookChannelType, message string, args []any) error
- func (s *Client) SendWithBlocks(channelType WebhookChannelType, blocks []map[string]any) error
- func (s *Client) Warnb(blocks []map[string]any) error
- func (s *Client) Warnf(message string, args ...any) error
- type FxLogger
- type WebhookChannelType
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Options( fx.Provide(NewSlackClient), fx.Decorate(NewFxLoggerFactory), )
Functions ¶
func NewFxLoggerFactory ¶
func NewFxLoggerFactory(fxLF di.FxLoggerFactory, slackClient *Client, lf *log.LoggerFactory) di.FxLoggerFactory
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewSlackClient ¶
func NewSlackClient(conf config.Config, lf *log.LoggerFactory) *Client
func (*Client) Send ¶
func (s *Client) Send(channelType WebhookChannelType, message string, args []any) error
func (*Client) SendWithBlocks ¶
func (s *Client) SendWithBlocks(channelType WebhookChannelType, blocks []map[string]any) error
type FxLogger ¶
type FxLogger struct {
// contains filtered or unexported fields
}
func NewFxLogger ¶
type WebhookChannelType ¶
type WebhookChannelType string
const ( WebhookChannelTypeInfo WebhookChannelType = "ℹ️ Info" WebhookChannelTypeWarn WebhookChannelType = "⚠️ Warn" WebhookChannelTypeError WebhookChannelType = "❗️Error" )
Click to show internal directories.
Click to hide internal directories.