// WithLogger sets the logger used internally by the service and by Log.
9726
func (service *Service) WithLogger(logger LogAdapter) {
	service.Context = WithLogger(service.Context, logger)
}
484552
func WithLogger(logger log.Logger) Option {
	return func(cw *CloudWatch) {
		cw.logger = logger
	}
}
644771
func Logger(ctx context.Context, args ...interface{}) log.Logger {
	loggerArgs := []interface{}{processPidKey, ctx.Value(processPidKey).(string), requestUuidKey, ctx.Value(requestUuidKey).(string)}
	args = append(loggerArgs, args...)

	additionnalLogElements := ctx.Value(additionnalLogElementsKey).(map[interface{}]interface{})
	for k, v := range additionnalLogElements {
		args = append(args, k, v)
	}

	return srvlog.New(args...)
}
623866
func (samplerOptions) Logger(logger Logger) SamplerOption {
	return func(o *samplerOptions) {
		o.logger = logger
	}
}
893275
func InitWithProvider(p logger.Provider) error {
	l := logger.New(p)
	l.SetLevel(LvINFO)
	return InitWithLogger(l)
}
102608
func WithWaiterLogger(logger aws.Logger) WaiterOption {
	return func(w *Waiter) {
		w.Logger = logger
	}
}
1198470
func (l *WAL) WithLogger(log *zap.Logger) {
	l.logger = log.With(zap.String("service", "wal"))
}
1202233
func (builder *StoreBucketPropsCommandBuilder) WithR(r uint32) *StoreBucketPropsCommandBuilder {
	builder.props.R = &r
	return builder
}
705123
func (b *Backend) Logger() log.Logger {
	if b.logger != nil {
		return b.logger
	}

	return logging.NewVaultLoggerWithWriter(ioutil.Discard, log.NoLevel)
}
54645
func Logger(ctx context.Context) *zap.Logger {
	if ctxlogger, ok := ctx.Value(ctxLogKey).(*zap.Logger); ok {
		return ctxlogger
	}
	return zaplog.L()
}
167811
func (r *Runtime) SetLogger(logger logger.Logger) {
	r.logger = logger
	middleware.Logger = logger
}
761013
func WithLogger(ctx context.Context, logger Logger) context.Context {
	return context.WithValue(ctx, loggerKey{}, logger)
}
11012
func Logger(logger *zap.Logger) TransportOption {
	return func(t *transportOptions) {
		t.logger = logger
	}
}
616185
func Logger(l log.FieldLogger) optSetter {
	return func(f *Forwarder) error {
		if logger, ok := l.(OxyLogger); ok {
			f.log = logger
			return nil
		}

		if logger, ok := l.(*log.Logger); ok {
			f.log = &internalLogger{Logger: logger}
			return nil
		}

		return errors.New("the type of the logger must be OxyLogger or logrus.Logger")
	}
}
862381
func WithLogger(ctx context.Context, l Logger) context.Context {
	return context.WithValue(ctx, loggerKey, l)
}
157850
func Logger(l *log.Logger) TokenLimiterOption {
	return func(tl *TokenLimiter) error {
		tl.log = l
		return nil
	}
}
1008586
func GetLoggerWithFields(ctx context.Context, fields map[interface{}]interface{}, keys ...interface{}) Logger {
	// must convert from interface{} -> interface{} to string -> interface{} for logrus.
	lfields := make(logrus.Fields, len(fields))
	for key, value := range fields {
		lfields[fmt.Sprint(key)] = value
	}

	return getLogrusLogger(ctx, keys...).WithFields(lfields)
}