harp_apps.proxy.settings.remote.probe¶
- class RemoteProbe[source]¶
Bases:
Stateful[RemoteProbeSettings]
Stateful version of a probe definition.
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- async check(client, endpoint)[source]¶
- Parameters:
client (AsyncClient)
endpoint (RemoteEndpoint)
- model_computed_fields: ClassVar[Dict[str, ComputedFieldInfo]] = {}¶
A dictionary of computed field names and their corresponding ComputedFieldInfo objects.
- model_config: ClassVar[ConfigDict] = {}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_fields: ClassVar[Dict[str, FieldInfo]] = {'settings': FieldInfo(annotation=RemoteProbeSettings, required=True, repr=False)}¶
Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo] objects.
This replaces Model.__fields__ from Pydantic V1.
- settings: Annotated[TSettings, Field(repr=False)]¶
- class RemoteProbeSettings[source]¶
Bases:
Configurable
A
HttpProbe
is a health check that can be used to check the health of a remote’s endpoints. It is used as the configuration parser forproxy.endpoints[].remote.probe
settings.type: http method: GET path: /health headers: x-purpose: "health probe" timeout: 5.0
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- model_computed_fields: ClassVar[Dict[str, ComputedFieldInfo]] = {}¶
A dictionary of computed field names and their corresponding ComputedFieldInfo objects.
- model_config: ClassVar[ConfigDict] = {'extra': 'forbid'}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_fields: ClassVar[Dict[str, FieldInfo]] = {'headers': FieldInfo(annotation=dict, required=False, default_factory=dict), 'interval': FieldInfo(annotation=float, required=False, default=10.0), 'method': FieldInfo(annotation=str, required=False, default='GET'), 'path': FieldInfo(annotation=str, required=False, default='/'), 'timeout': FieldInfo(annotation=float, required=False, default=10.0), 'verify': FieldInfo(annotation=bool, required=False, default=True)}¶
Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo] objects.
This replaces Model.__fields__ from Pydantic V1.