proxy-pool/internal/platform/admission/allow_all.go
2026-07-30 11:38:33 +08:00

15 lines
362 B
Go

package admission
import "context"
// AllowAll validates the common admission contract without applying another
// quota. It is used when an outer transport boundary already owns rate limits.
type AllowAll struct{}
func (AllowAll) Admit(ctx context.Context, key string) error {
if ctx == nil || key == "" {
return ErrInvalidIdentity
}
return ctx.Err()
}