Documentation
¶
Index ¶
- func NewInvalidInputError(v interface{}) error
- func NewInvalidOutputError(v interface{}) error
- func NewMethodNotFoundError(name string) error
- type AsyncConfigurer
- type CacheableProvider
- type Executable
- type HasMethodRetryPolicy
- type HasMethodToolTimeout
- type HasToolTimeout
- type Service
- type Signature
- type Signatures
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewInvalidInputError ¶
func NewInvalidInputError(v interface{}) error
func NewInvalidOutputError ¶
func NewInvalidOutputError(v interface{}) error
func NewMethodNotFoundError ¶
Types ¶
type AsyncConfigurer ¶ added in v0.1.7
type CacheableProvider ¶ added in v0.1.7
CacheableProvider can be implemented by services to declare which methods produce cacheable (supersession-eligible) outputs. The registry queries this at AddInternalService time. Keys are method names (e.g., "status", "list"); values indicate cacheability.
type Executable ¶
Executable represents a callable method accepting an input value and writing into the provided output. Implementations should return an error on failure.
type HasMethodRetryPolicy ¶ added in v0.1.23
type HasMethodRetryPolicy interface {
MethodRetryable(method string) (retryable bool, configured bool)
}
HasMethodRetryPolicy can be implemented by services that need to override the default retry behavior for individual methods. The second return value reports whether the method has an explicit policy.
type HasMethodToolTimeout ¶ added in v0.1.23
HasMethodToolTimeout can be implemented by services whose methods need different execution timeouts. A non-positive duration preserves the registry's normal timeout behavior for that method.
type HasToolTimeout ¶
HasToolTimeout can be implemented by services to suggest a per-tool execution timeout. Registries may honor this when executing the service. Returned duration should be >0 to take effect.
type Service ¶
type Service interface {
Name() string
Methods() Signatures
Method(name string) (Executable, error)
}
Service is a minimal abstraction grouping a set of executable methods.
type Signature ¶
type Signature struct {
Name string
Description string
Internal bool
Input reflect.Type
Output reflect.Type
}
Signature describes a single method exposed by a Service.
type Signatures ¶
type Signatures []Signature
Signatures is an ordered collection of method signatures.