Documentation ¶
Index ¶
- func New(baseURL, accessToken, datasetName string, options ...Option) (zapcore.Core, error)
- func NewCloud(accessToken, orgID, datasetName string, options ...Option) (zapcore.Core, error)
- func NewWithClient(client *axiom.Client, datasetName string, options ...Option) (zapcore.Core, error)
- type Option
- type WriteSyncer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
New creates a new zapcore.Core configured to talk to the specified Axiom deployment and authenticating with the given access token. An ingest token is sufficient enough. The logs will be ingested into the specified dataset. Additional options can be supplied to configure the core.
Types ¶
type Option ¶
type Option func(*WriteSyncer) error
An Option modifies the behaviour of the Axiom WriteSyncer.
func IngestOptions ¶
func IngestOptions(opts axiom.IngestOptions) Option
IngestOptions specifies the ingestion options to use for ingesting the logs.
func LevelEnabler ¶
func LevelEnabler(levelEnabler zapcore.LevelEnabler) Option
LevelEnabler sets the level enabler that the Axiom WriteSyncer will us to determine if logs will be shipped to Axiom.
type WriteSyncer ¶
type WriteSyncer struct {
// contains filtered or unexported fields
}
WriteSyncer implements a zapcore.WriteSyncer used for shipping logs to Axiom.
Click to show internal directories.
Click to hide internal directories.