mirror of
https://github.com/foomo/keel.git
synced 2025-10-16 12:35:34 +00:00
24 lines
567 B
Go
24 lines
567 B
Go
package log
|
|
|
|
import (
|
|
semconv "go.opentelemetry.io/otel/semconv/v1.37.0"
|
|
"go.uber.org/zap"
|
|
)
|
|
|
|
const (
|
|
// Deprecated: use semconv messaging attributes instead.
|
|
NetHostIPKey = "net_host_ip"
|
|
// Deprecated: use semconv messaging attributes instead.
|
|
NetHostPortKey = "net_host_port"
|
|
)
|
|
|
|
// Deprecated: use semconv messaging attributes instead.
|
|
func FNetHostIP(ip string) zap.Field {
|
|
return Attribute(semconv.HostIP(ip))
|
|
}
|
|
|
|
// Deprecated: use semconv messaging attributes instead.
|
|
func FNetHostPort(port string) zap.Field {
|
|
return zap.String(NetHostPortKey, port)
|
|
}
|