Documentation ¶
Index ¶
- func Debug(ctx context.Context) auloggingapi.LeveledLoggingImplementation
- func Info(ctx context.Context) auloggingapi.LeveledLoggingImplementation
- func New(wrapped aurestclientapi.Client) aurestclientapi.Client
- func NewWithOptions(wrapped aurestclientapi.Client, opts RequestLoggingOptions) aurestclientapi.Client
- func Warn(ctx context.Context) auloggingapi.LeveledLoggingImplementation
- type RequestLoggingImpl
- type RequestLoggingOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Debug ¶ added in v0.8.0
func Debug(ctx context.Context) auloggingapi.LeveledLoggingImplementation
func Info ¶ added in v0.8.0
func Info(ctx context.Context) auloggingapi.LeveledLoggingImplementation
func New ¶
func New(wrapped aurestclientapi.Client) aurestclientapi.Client
func NewWithOptions ¶ added in v0.8.0
func NewWithOptions(wrapped aurestclientapi.Client, opts RequestLoggingOptions) aurestclientapi.Client
func Warn ¶ added in v0.8.0
func Warn(ctx context.Context) auloggingapi.LeveledLoggingImplementation
Types ¶
type RequestLoggingImpl ¶
type RequestLoggingImpl struct { Wrapped aurestclientapi.Client Options RequestLoggingOptions }
func (*RequestLoggingImpl) Perform ¶
func (c *RequestLoggingImpl) Perform(ctx context.Context, method string, requestUrl string, requestBody interface{}, response *aurestclientapi.ParsedResponse) error
type RequestLoggingOptions ¶ added in v0.8.0
type RequestLoggingOptions struct { BeforeRequest func(ctx context.Context) auloggingapi.LeveledLoggingImplementation Success func(ctx context.Context) auloggingapi.LeveledLoggingImplementation Failure func(ctx context.Context) auloggingapi.LeveledLoggingImplementation }
RequestLoggingOptions allows overriding the log functions used.
This allows easily changing the log level when setting up request logging.
important: do not cache the LeveledLoggingImplementation, create one each time, or some loggers may use cached values.
Click to show internal directories.
Click to hide internal directories.