Merge pull request #39 from vibe/main
feat: generate extra resources proto
This commit is contained in:
commit
4ea7a909ef
|
@ -61,6 +61,19 @@ message RunFunctionRequest {
|
|||
// and that context will be passed to subsequent Functions. Crossplane
|
||||
// discards all context returned by the last Function in the pipeline.
|
||||
optional google.protobuf.Struct context = 5;
|
||||
|
||||
// Optional extra resources that the Function required.
|
||||
// Note that extra resources is a map to Resources, plural.
|
||||
// The map key corresponds to the key in a RunFunctionResponse's
|
||||
// extra_resources field. If a Function requested extra resources that
|
||||
// did not exist, Crossplane sets the map key to an empty Resources message to
|
||||
// indicate that it attempted to satisfy the request.
|
||||
map<string, Resources> extra_resources = 6;
|
||||
}
|
||||
|
||||
// Resources represents the state of several Crossplane resources.
|
||||
message Resources {
|
||||
repeated Resource items = 1;
|
||||
}
|
||||
|
||||
// A RunFunctionResponse contains the result of a Composition Function run.
|
||||
|
@ -88,6 +101,9 @@ message RunFunctionResponse {
|
|||
// Optional context to be passed to the next Function in the pipeline as part
|
||||
// of the RunFunctionRequest. Dropped on the last function in the pipeline.
|
||||
optional google.protobuf.Struct context = 4;
|
||||
|
||||
// Requirements that must be satisfied for this Function to run successfully.
|
||||
Requirements requirements = 5;
|
||||
}
|
||||
|
||||
// RequestMeta contains metadata pertaining to a RunFunctionRequest.
|
||||
|
@ -97,6 +113,29 @@ message RequestMeta {
|
|||
string tag = 1;
|
||||
}
|
||||
|
||||
// Requirements that must be satisfied for a Function to run successfully.
|
||||
message Requirements {
|
||||
// Extra resources that this Function requires.
|
||||
// The map key uniquely identifies the group of resources.
|
||||
map<string, ResourceSelector> extra_resources = 1;
|
||||
}
|
||||
|
||||
// ResourceSelector selects a group of resources, either by name or by label.
|
||||
message ResourceSelector {
|
||||
string api_version = 1;
|
||||
string kind = 2;
|
||||
|
||||
oneof match {
|
||||
string match_name = 3;
|
||||
MatchLabels match_labels = 4;
|
||||
}
|
||||
}
|
||||
|
||||
// MatchLabels defines a set of labels to match resources against.
|
||||
message MatchLabels {
|
||||
map<string, string> labels = 1;
|
||||
}
|
||||
|
||||
// ResponseMeta contains metadata pertaining to a RunFunctionResponse.
|
||||
message ResponseMeta {
|
||||
// An opaque string identifying the content of the request. Must match the
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: crossplane/function/proto/v1beta1/run_function.proto
|
||||
# Protobuf Python Version: 4.25.0
|
||||
"""Generated protocol buffer code."""
|
||||
from google.protobuf import descriptor as _descriptor
|
||||
from google.protobuf import descriptor_pool as _descriptor_pool
|
||||
|
@ -15,39 +16,59 @@ from google.protobuf import struct_pb2 as google_dot_protobuf_dot_struct__pb2
|
|||
from google.protobuf import duration_pb2 as google_dot_protobuf_dot_duration__pb2
|
||||
|
||||
|
||||
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n4crossplane/function/proto/v1beta1/run_function.proto\x12\x1e\x61piextensions.fn.proto.v1beta1\x1a\x1cgoogle/protobuf/struct.proto\x1a\x1egoogle/protobuf/duration.proto\"\xb2\x02\n\x12RunFunctionRequest\x12\x39\n\x04meta\x18\x01 \x01(\x0b\x32+.apiextensions.fn.proto.v1beta1.RequestMeta\x12\x37\n\x08observed\x18\x02 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12\x36\n\x07\x64\x65sired\x18\x03 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12+\n\x05input\x18\x04 \x01(\x0b\x32\x17.google.protobuf.StructH\x00\x88\x01\x01\x12-\n\x07\x63ontext\x18\x05 \x01(\x0b\x32\x17.google.protobuf.StructH\x01\x88\x01\x01\x42\x08\n\x06_inputB\n\n\x08_context\"\xfd\x01\n\x13RunFunctionResponse\x12:\n\x04meta\x18\x01 \x01(\x0b\x32,.apiextensions.fn.proto.v1beta1.ResponseMeta\x12\x36\n\x07\x64\x65sired\x18\x02 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12\x37\n\x07results\x18\x03 \x03(\x0b\x32&.apiextensions.fn.proto.v1beta1.Result\x12-\n\x07\x63ontext\x18\x04 \x01(\x0b\x32\x17.google.protobuf.StructH\x00\x88\x01\x01\x42\n\n\x08_context\"\x1a\n\x0bRequestMeta\x12\x0b\n\x03tag\x18\x01 \x01(\t\"P\n\x0cResponseMeta\x12\x0b\n\x03tag\x18\x01 \x01(\t\x12+\n\x03ttl\x18\x02 \x01(\x0b\x32\x19.google.protobuf.DurationH\x00\x88\x01\x01\x42\x06\n\x04_ttl\"\xe9\x01\n\x05State\x12;\n\tcomposite\x18\x01 \x01(\x0b\x32(.apiextensions.fn.proto.v1beta1.Resource\x12G\n\tresources\x18\x02 \x03(\x0b\x32\x34.apiextensions.fn.proto.v1beta1.State.ResourcesEntry\x1aZ\n\x0eResourcesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x37\n\x05value\x18\x02 \x01(\x0b\x32(.apiextensions.fn.proto.v1beta1.Resource:\x02\x38\x01\"\x82\x02\n\x08Resource\x12)\n\x08resource\x18\x01 \x01(\x0b\x32\x17.google.protobuf.Struct\x12[\n\x12\x63onnection_details\x18\x02 \x03(\x0b\x32?.apiextensions.fn.proto.v1beta1.Resource.ConnectionDetailsEntry\x12\x34\n\x05ready\x18\x03 \x01(\x0e\x32%.apiextensions.fn.proto.v1beta1.Ready\x1a\x38\n\x16\x43onnectionDetailsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\"U\n\x06Result\x12:\n\x08severity\x18\x01 \x01(\x0e\x32(.apiextensions.fn.proto.v1beta1.Severity\x12\x0f\n\x07message\x18\x02 \x01(\t*?\n\x05Ready\x12\x15\n\x11READY_UNSPECIFIED\x10\x00\x12\x0e\n\nREADY_TRUE\x10\x01\x12\x0f\n\x0bREADY_FALSE\x10\x02*c\n\x08Severity\x12\x18\n\x14SEVERITY_UNSPECIFIED\x10\x00\x12\x12\n\x0eSEVERITY_FATAL\x10\x01\x12\x14\n\x10SEVERITY_WARNING\x10\x02\x12\x13\n\x0fSEVERITY_NORMAL\x10\x03\x32\x91\x01\n\x15\x46unctionRunnerService\x12x\n\x0bRunFunction\x12\x32.apiextensions.fn.proto.v1beta1.RunFunctionRequest\x1a\x33.apiextensions.fn.proto.v1beta1.RunFunctionResponse\"\x00\x62\x06proto3')
|
||||
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n4crossplane/function/proto/v1beta1/run_function.proto\x12\x1e\x61piextensions.fn.proto.v1beta1\x1a\x1cgoogle/protobuf/struct.proto\x1a\x1egoogle/protobuf/duration.proto\"\xf5\x03\n\x12RunFunctionRequest\x12\x39\n\x04meta\x18\x01 \x01(\x0b\x32+.apiextensions.fn.proto.v1beta1.RequestMeta\x12\x37\n\x08observed\x18\x02 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12\x36\n\x07\x64\x65sired\x18\x03 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12+\n\x05input\x18\x04 \x01(\x0b\x32\x17.google.protobuf.StructH\x00\x88\x01\x01\x12-\n\x07\x63ontext\x18\x05 \x01(\x0b\x32\x17.google.protobuf.StructH\x01\x88\x01\x01\x12_\n\x0f\x65xtra_resources\x18\x06 \x03(\x0b\x32\x46.apiextensions.fn.proto.v1beta1.RunFunctionRequest.ExtraResourcesEntry\x1a`\n\x13\x45xtraResourcesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x38\n\x05value\x18\x02 \x01(\x0b\x32).apiextensions.fn.proto.v1beta1.Resources:\x02\x38\x01\x42\x08\n\x06_inputB\n\n\x08_context\"D\n\tResources\x12\x37\n\x05items\x18\x01 \x03(\x0b\x32(.apiextensions.fn.proto.v1beta1.Resource\"\xc1\x02\n\x13RunFunctionResponse\x12:\n\x04meta\x18\x01 \x01(\x0b\x32,.apiextensions.fn.proto.v1beta1.ResponseMeta\x12\x36\n\x07\x64\x65sired\x18\x02 \x01(\x0b\x32%.apiextensions.fn.proto.v1beta1.State\x12\x37\n\x07results\x18\x03 \x03(\x0b\x32&.apiextensions.fn.proto.v1beta1.Result\x12-\n\x07\x63ontext\x18\x04 \x01(\x0b\x32\x17.google.protobuf.StructH\x00\x88\x01\x01\x12\x42\n\x0crequirements\x18\x05 \x01(\x0b\x32,.apiextensions.fn.proto.v1beta1.RequirementsB\n\n\x08_context\"\x1a\n\x0bRequestMeta\x12\x0b\n\x03tag\x18\x01 \x01(\t\"\xd2\x01\n\x0cRequirements\x12Y\n\x0f\x65xtra_resources\x18\x01 \x03(\x0b\x32@.apiextensions.fn.proto.v1beta1.Requirements.ExtraResourcesEntry\x1ag\n\x13\x45xtraResourcesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12?\n\x05value\x18\x02 \x01(\x0b\x32\x30.apiextensions.fn.proto.v1beta1.ResourceSelector:\x02\x38\x01\"\x99\x01\n\x10ResourceSelector\x12\x13\n\x0b\x61pi_version\x18\x01 \x01(\t\x12\x0c\n\x04kind\x18\x02 \x01(\t\x12\x14\n\nmatch_name\x18\x03 \x01(\tH\x00\x12\x43\n\x0cmatch_labels\x18\x04 \x01(\x0b\x32+.apiextensions.fn.proto.v1beta1.MatchLabelsH\x00\x42\x07\n\x05match\"\x85\x01\n\x0bMatchLabels\x12G\n\x06labels\x18\x01 \x03(\x0b\x32\x37.apiextensions.fn.proto.v1beta1.MatchLabels.LabelsEntry\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"P\n\x0cResponseMeta\x12\x0b\n\x03tag\x18\x01 \x01(\t\x12+\n\x03ttl\x18\x02 \x01(\x0b\x32\x19.google.protobuf.DurationH\x00\x88\x01\x01\x42\x06\n\x04_ttl\"\xe9\x01\n\x05State\x12;\n\tcomposite\x18\x01 \x01(\x0b\x32(.apiextensions.fn.proto.v1beta1.Resource\x12G\n\tresources\x18\x02 \x03(\x0b\x32\x34.apiextensions.fn.proto.v1beta1.State.ResourcesEntry\x1aZ\n\x0eResourcesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x37\n\x05value\x18\x02 \x01(\x0b\x32(.apiextensions.fn.proto.v1beta1.Resource:\x02\x38\x01\"\x82\x02\n\x08Resource\x12)\n\x08resource\x18\x01 \x01(\x0b\x32\x17.google.protobuf.Struct\x12[\n\x12\x63onnection_details\x18\x02 \x03(\x0b\x32?.apiextensions.fn.proto.v1beta1.Resource.ConnectionDetailsEntry\x12\x34\n\x05ready\x18\x03 \x01(\x0e\x32%.apiextensions.fn.proto.v1beta1.Ready\x1a\x38\n\x16\x43onnectionDetailsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\"U\n\x06Result\x12:\n\x08severity\x18\x01 \x01(\x0e\x32(.apiextensions.fn.proto.v1beta1.Severity\x12\x0f\n\x07message\x18\x02 \x01(\t*?\n\x05Ready\x12\x15\n\x11READY_UNSPECIFIED\x10\x00\x12\x0e\n\nREADY_TRUE\x10\x01\x12\x0f\n\x0bREADY_FALSE\x10\x02*c\n\x08Severity\x12\x18\n\x14SEVERITY_UNSPECIFIED\x10\x00\x12\x12\n\x0eSEVERITY_FATAL\x10\x01\x12\x14\n\x10SEVERITY_WARNING\x10\x02\x12\x13\n\x0fSEVERITY_NORMAL\x10\x03\x32\x91\x01\n\x15\x46unctionRunnerService\x12x\n\x0bRunFunction\x12\x32.apiextensions.fn.proto.v1beta1.RunFunctionRequest\x1a\x33.apiextensions.fn.proto.v1beta1.RunFunctionResponse\"\x00\x62\x06proto3')
|
||||
|
||||
_globals = globals()
|
||||
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
||||
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'crossplane.function.proto.v1beta1.run_function_pb2', _globals)
|
||||
if _descriptor._USE_C_DESCRIPTORS == False:
|
||||
DESCRIPTOR._options = None
|
||||
_STATE_RESOURCESENTRY._options = None
|
||||
_STATE_RESOURCESENTRY._serialized_options = b'8\001'
|
||||
_RESOURCE_CONNECTIONDETAILSENTRY._options = None
|
||||
_RESOURCE_CONNECTIONDETAILSENTRY._serialized_options = b'8\001'
|
||||
_globals['_READY']._serialized_start=1409
|
||||
_globals['_READY']._serialized_end=1472
|
||||
_globals['_SEVERITY']._serialized_start=1474
|
||||
_globals['_SEVERITY']._serialized_end=1573
|
||||
_globals['_RUNFUNCTIONREQUEST_EXTRARESOURCESENTRY']._options = None
|
||||
_globals['_RUNFUNCTIONREQUEST_EXTRARESOURCESENTRY']._serialized_options = b'8\001'
|
||||
_globals['_REQUIREMENTS_EXTRARESOURCESENTRY']._options = None
|
||||
_globals['_REQUIREMENTS_EXTRARESOURCESENTRY']._serialized_options = b'8\001'
|
||||
_globals['_MATCHLABELS_LABELSENTRY']._options = None
|
||||
_globals['_MATCHLABELS_LABELSENTRY']._serialized_options = b'8\001'
|
||||
_globals['_STATE_RESOURCESENTRY']._options = None
|
||||
_globals['_STATE_RESOURCESENTRY']._serialized_options = b'8\001'
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._options = None
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._serialized_options = b'8\001'
|
||||
_globals['_READY']._serialized_start=2247
|
||||
_globals['_READY']._serialized_end=2310
|
||||
_globals['_SEVERITY']._serialized_start=2312
|
||||
_globals['_SEVERITY']._serialized_end=2411
|
||||
_globals['_RUNFUNCTIONREQUEST']._serialized_start=151
|
||||
_globals['_RUNFUNCTIONREQUEST']._serialized_end=457
|
||||
_globals['_RUNFUNCTIONRESPONSE']._serialized_start=460
|
||||
_globals['_RUNFUNCTIONRESPONSE']._serialized_end=713
|
||||
_globals['_REQUESTMETA']._serialized_start=715
|
||||
_globals['_REQUESTMETA']._serialized_end=741
|
||||
_globals['_RESPONSEMETA']._serialized_start=743
|
||||
_globals['_RESPONSEMETA']._serialized_end=823
|
||||
_globals['_STATE']._serialized_start=826
|
||||
_globals['_STATE']._serialized_end=1059
|
||||
_globals['_STATE_RESOURCESENTRY']._serialized_start=969
|
||||
_globals['_STATE_RESOURCESENTRY']._serialized_end=1059
|
||||
_globals['_RESOURCE']._serialized_start=1062
|
||||
_globals['_RESOURCE']._serialized_end=1320
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._serialized_start=1264
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._serialized_end=1320
|
||||
_globals['_RESULT']._serialized_start=1322
|
||||
_globals['_RESULT']._serialized_end=1407
|
||||
_globals['_FUNCTIONRUNNERSERVICE']._serialized_start=1576
|
||||
_globals['_FUNCTIONRUNNERSERVICE']._serialized_end=1721
|
||||
_globals['_RUNFUNCTIONREQUEST']._serialized_end=652
|
||||
_globals['_RUNFUNCTIONREQUEST_EXTRARESOURCESENTRY']._serialized_start=534
|
||||
_globals['_RUNFUNCTIONREQUEST_EXTRARESOURCESENTRY']._serialized_end=630
|
||||
_globals['_RESOURCES']._serialized_start=654
|
||||
_globals['_RESOURCES']._serialized_end=722
|
||||
_globals['_RUNFUNCTIONRESPONSE']._serialized_start=725
|
||||
_globals['_RUNFUNCTIONRESPONSE']._serialized_end=1046
|
||||
_globals['_REQUESTMETA']._serialized_start=1048
|
||||
_globals['_REQUESTMETA']._serialized_end=1074
|
||||
_globals['_REQUIREMENTS']._serialized_start=1077
|
||||
_globals['_REQUIREMENTS']._serialized_end=1287
|
||||
_globals['_REQUIREMENTS_EXTRARESOURCESENTRY']._serialized_start=1184
|
||||
_globals['_REQUIREMENTS_EXTRARESOURCESENTRY']._serialized_end=1287
|
||||
_globals['_RESOURCESELECTOR']._serialized_start=1290
|
||||
_globals['_RESOURCESELECTOR']._serialized_end=1443
|
||||
_globals['_MATCHLABELS']._serialized_start=1446
|
||||
_globals['_MATCHLABELS']._serialized_end=1579
|
||||
_globals['_MATCHLABELS_LABELSENTRY']._serialized_start=1534
|
||||
_globals['_MATCHLABELS_LABELSENTRY']._serialized_end=1579
|
||||
_globals['_RESPONSEMETA']._serialized_start=1581
|
||||
_globals['_RESPONSEMETA']._serialized_end=1661
|
||||
_globals['_STATE']._serialized_start=1664
|
||||
_globals['_STATE']._serialized_end=1897
|
||||
_globals['_STATE_RESOURCESENTRY']._serialized_start=1807
|
||||
_globals['_STATE_RESOURCESENTRY']._serialized_end=1897
|
||||
_globals['_RESOURCE']._serialized_start=1900
|
||||
_globals['_RESOURCE']._serialized_end=2158
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._serialized_start=2102
|
||||
_globals['_RESOURCE_CONNECTIONDETAILSENTRY']._serialized_end=2158
|
||||
_globals['_RESULT']._serialized_start=2160
|
||||
_globals['_RESULT']._serialized_end=2245
|
||||
_globals['_FUNCTIONRUNNERSERVICE']._serialized_start=2414
|
||||
_globals['_FUNCTIONRUNNERSERVICE']._serialized_end=2559
|
||||
# @@protoc_insertion_point(module_scope)
|
||||
|
|
|
@ -9,13 +9,13 @@ from typing import ClassVar as _ClassVar, Iterable as _Iterable, Mapping as _Map
|
|||
DESCRIPTOR: _descriptor.FileDescriptor
|
||||
|
||||
class Ready(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
||||
__slots__ = []
|
||||
__slots__ = ()
|
||||
READY_UNSPECIFIED: _ClassVar[Ready]
|
||||
READY_TRUE: _ClassVar[Ready]
|
||||
READY_FALSE: _ClassVar[Ready]
|
||||
|
||||
class Severity(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
||||
__slots__ = []
|
||||
__slots__ = ()
|
||||
SEVERITY_UNSPECIFIED: _ClassVar[Severity]
|
||||
SEVERITY_FATAL: _ClassVar[Severity]
|
||||
SEVERITY_WARNING: _ClassVar[Severity]
|
||||
|
@ -29,39 +29,94 @@ SEVERITY_WARNING: Severity
|
|||
SEVERITY_NORMAL: Severity
|
||||
|
||||
class RunFunctionRequest(_message.Message):
|
||||
__slots__ = ["meta", "observed", "desired", "input", "context"]
|
||||
__slots__ = ("meta", "observed", "desired", "input", "context", "extra_resources")
|
||||
class ExtraResourcesEntry(_message.Message):
|
||||
__slots__ = ("key", "value")
|
||||
KEY_FIELD_NUMBER: _ClassVar[int]
|
||||
VALUE_FIELD_NUMBER: _ClassVar[int]
|
||||
key: str
|
||||
value: Resources
|
||||
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[Resources, _Mapping]] = ...) -> None: ...
|
||||
META_FIELD_NUMBER: _ClassVar[int]
|
||||
OBSERVED_FIELD_NUMBER: _ClassVar[int]
|
||||
DESIRED_FIELD_NUMBER: _ClassVar[int]
|
||||
INPUT_FIELD_NUMBER: _ClassVar[int]
|
||||
CONTEXT_FIELD_NUMBER: _ClassVar[int]
|
||||
EXTRA_RESOURCES_FIELD_NUMBER: _ClassVar[int]
|
||||
meta: RequestMeta
|
||||
observed: State
|
||||
desired: State
|
||||
input: _struct_pb2.Struct
|
||||
context: _struct_pb2.Struct
|
||||
def __init__(self, meta: _Optional[_Union[RequestMeta, _Mapping]] = ..., observed: _Optional[_Union[State, _Mapping]] = ..., desired: _Optional[_Union[State, _Mapping]] = ..., input: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., context: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ...) -> None: ...
|
||||
extra_resources: _containers.MessageMap[str, Resources]
|
||||
def __init__(self, meta: _Optional[_Union[RequestMeta, _Mapping]] = ..., observed: _Optional[_Union[State, _Mapping]] = ..., desired: _Optional[_Union[State, _Mapping]] = ..., input: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., context: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., extra_resources: _Optional[_Mapping[str, Resources]] = ...) -> None: ...
|
||||
|
||||
class Resources(_message.Message):
|
||||
__slots__ = ("items",)
|
||||
ITEMS_FIELD_NUMBER: _ClassVar[int]
|
||||
items: _containers.RepeatedCompositeFieldContainer[Resource]
|
||||
def __init__(self, items: _Optional[_Iterable[_Union[Resource, _Mapping]]] = ...) -> None: ...
|
||||
|
||||
class RunFunctionResponse(_message.Message):
|
||||
__slots__ = ["meta", "desired", "results", "context"]
|
||||
__slots__ = ("meta", "desired", "results", "context", "requirements")
|
||||
META_FIELD_NUMBER: _ClassVar[int]
|
||||
DESIRED_FIELD_NUMBER: _ClassVar[int]
|
||||
RESULTS_FIELD_NUMBER: _ClassVar[int]
|
||||
CONTEXT_FIELD_NUMBER: _ClassVar[int]
|
||||
REQUIREMENTS_FIELD_NUMBER: _ClassVar[int]
|
||||
meta: ResponseMeta
|
||||
desired: State
|
||||
results: _containers.RepeatedCompositeFieldContainer[Result]
|
||||
context: _struct_pb2.Struct
|
||||
def __init__(self, meta: _Optional[_Union[ResponseMeta, _Mapping]] = ..., desired: _Optional[_Union[State, _Mapping]] = ..., results: _Optional[_Iterable[_Union[Result, _Mapping]]] = ..., context: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ...) -> None: ...
|
||||
requirements: Requirements
|
||||
def __init__(self, meta: _Optional[_Union[ResponseMeta, _Mapping]] = ..., desired: _Optional[_Union[State, _Mapping]] = ..., results: _Optional[_Iterable[_Union[Result, _Mapping]]] = ..., context: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., requirements: _Optional[_Union[Requirements, _Mapping]] = ...) -> None: ...
|
||||
|
||||
class RequestMeta(_message.Message):
|
||||
__slots__ = ["tag"]
|
||||
__slots__ = ("tag",)
|
||||
TAG_FIELD_NUMBER: _ClassVar[int]
|
||||
tag: str
|
||||
def __init__(self, tag: _Optional[str] = ...) -> None: ...
|
||||
|
||||
class Requirements(_message.Message):
|
||||
__slots__ = ("extra_resources",)
|
||||
class ExtraResourcesEntry(_message.Message):
|
||||
__slots__ = ("key", "value")
|
||||
KEY_FIELD_NUMBER: _ClassVar[int]
|
||||
VALUE_FIELD_NUMBER: _ClassVar[int]
|
||||
key: str
|
||||
value: ResourceSelector
|
||||
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[ResourceSelector, _Mapping]] = ...) -> None: ...
|
||||
EXTRA_RESOURCES_FIELD_NUMBER: _ClassVar[int]
|
||||
extra_resources: _containers.MessageMap[str, ResourceSelector]
|
||||
def __init__(self, extra_resources: _Optional[_Mapping[str, ResourceSelector]] = ...) -> None: ...
|
||||
|
||||
class ResourceSelector(_message.Message):
|
||||
__slots__ = ("api_version", "kind", "match_name", "match_labels")
|
||||
API_VERSION_FIELD_NUMBER: _ClassVar[int]
|
||||
KIND_FIELD_NUMBER: _ClassVar[int]
|
||||
MATCH_NAME_FIELD_NUMBER: _ClassVar[int]
|
||||
MATCH_LABELS_FIELD_NUMBER: _ClassVar[int]
|
||||
api_version: str
|
||||
kind: str
|
||||
match_name: str
|
||||
match_labels: MatchLabels
|
||||
def __init__(self, api_version: _Optional[str] = ..., kind: _Optional[str] = ..., match_name: _Optional[str] = ..., match_labels: _Optional[_Union[MatchLabels, _Mapping]] = ...) -> None: ...
|
||||
|
||||
class MatchLabels(_message.Message):
|
||||
__slots__ = ("labels",)
|
||||
class LabelsEntry(_message.Message):
|
||||
__slots__ = ("key", "value")
|
||||
KEY_FIELD_NUMBER: _ClassVar[int]
|
||||
VALUE_FIELD_NUMBER: _ClassVar[int]
|
||||
key: str
|
||||
value: str
|
||||
def __init__(self, key: _Optional[str] = ..., value: _Optional[str] = ...) -> None: ...
|
||||
LABELS_FIELD_NUMBER: _ClassVar[int]
|
||||
labels: _containers.ScalarMap[str, str]
|
||||
def __init__(self, labels: _Optional[_Mapping[str, str]] = ...) -> None: ...
|
||||
|
||||
class ResponseMeta(_message.Message):
|
||||
__slots__ = ["tag", "ttl"]
|
||||
__slots__ = ("tag", "ttl")
|
||||
TAG_FIELD_NUMBER: _ClassVar[int]
|
||||
TTL_FIELD_NUMBER: _ClassVar[int]
|
||||
tag: str
|
||||
|
@ -69,9 +124,9 @@ class ResponseMeta(_message.Message):
|
|||
def __init__(self, tag: _Optional[str] = ..., ttl: _Optional[_Union[_duration_pb2.Duration, _Mapping]] = ...) -> None: ...
|
||||
|
||||
class State(_message.Message):
|
||||
__slots__ = ["composite", "resources"]
|
||||
__slots__ = ("composite", "resources")
|
||||
class ResourcesEntry(_message.Message):
|
||||
__slots__ = ["key", "value"]
|
||||
__slots__ = ("key", "value")
|
||||
KEY_FIELD_NUMBER: _ClassVar[int]
|
||||
VALUE_FIELD_NUMBER: _ClassVar[int]
|
||||
key: str
|
||||
|
@ -84,9 +139,9 @@ class State(_message.Message):
|
|||
def __init__(self, composite: _Optional[_Union[Resource, _Mapping]] = ..., resources: _Optional[_Mapping[str, Resource]] = ...) -> None: ...
|
||||
|
||||
class Resource(_message.Message):
|
||||
__slots__ = ["resource", "connection_details", "ready"]
|
||||
__slots__ = ("resource", "connection_details", "ready")
|
||||
class ConnectionDetailsEntry(_message.Message):
|
||||
__slots__ = ["key", "value"]
|
||||
__slots__ = ("key", "value")
|
||||
KEY_FIELD_NUMBER: _ClassVar[int]
|
||||
VALUE_FIELD_NUMBER: _ClassVar[int]
|
||||
key: str
|
||||
|
@ -101,7 +156,7 @@ class Resource(_message.Message):
|
|||
def __init__(self, resource: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., connection_details: _Optional[_Mapping[str, bytes]] = ..., ready: _Optional[_Union[Ready, str]] = ...) -> None: ...
|
||||
|
||||
class Result(_message.Message):
|
||||
__slots__ = ["severity", "message"]
|
||||
__slots__ = ("severity", "message")
|
||||
SEVERITY_FIELD_NUMBER: _ClassVar[int]
|
||||
MESSAGE_FIELD_NUMBER: _ClassVar[int]
|
||||
severity: Severity
|
||||
|
|
Loading…
Reference in New Issue