Documentation
¶
Overview ¶
Package strings provides HTTP-specific string helpers for net-layer middleware.
This package contains small helpers used by HTTP middleware and telemetry code, including matching service-owned operational endpoints such as health and metrics routes that are typically ignored by auth, limiter, and logging middleware.
Start with IsOperationPath.
Index ¶
- Constants
- func Bytes(s string) []byte
- func Concat(ss ...string) string
- func Contains(s, substr string) bool
- func Cut(s, sep string) (string, string, bool)
- func IsEmpty(s string) bool
- func IsOperationPath(name env.Name, path string) bool
- func Join(sep string, ss ...string) string
- func ToLower(s string) string
Constants ¶
View Source
const ( // Empty is an alias for [strings.Empty]. Empty = strings.Empty // Space is an alias for [strings.Space]. Space = strings.Space )
Variables ¶
This section is empty.
Functions ¶
func IsOperationPath ¶ added in v2.413.0
IsOperationPath reports whether path is a service-owned operational endpoint.
Matching is exact so application routes such as "/admin/metrics" are not treated as transport operation endpoints for auth or rate-limit bypasses.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.