1 - | import constraints_without_public_constrained_types.input
|
2 - | import constraints_without_public_constrained_types.middleware
|
3 - | import constraints_without_public_constrained_types.output
|
4 - | import constraints_without_public_constrained_types.tls
|
5 - | import typing
|
6 - |
|
7 - | Ctx = typing.TypeVar('Ctx')
|
8 - |
|
9 - | class App(typing.Generic[Ctx]):
|
10 - | """
|
11 - | Main Python application, used to register operations and context and start multiple
|
12 - | workers on the same shared socket.
|
13 - |
|
14 - | Operations can be registered using the application object as a decorator (`@app.operation_name`).
|
15 - |
|
16 - | Here's a full example to get you started:
|
17 - |
|
18 - | ```python
|
19 - | from constraints_without_public_constrained_types import input
|
20 - | from constraints_without_public_constrained_types import output
|
21 - | from constraints_without_public_constrained_types import error
|
22 - | from constraints_without_public_constrained_types import middleware
|
23 - | from constraints_without_public_constrained_types import App
|
24 - |
|
25 - | @dataclass
|
26 - | class Context:
|
27 - | counter: int = 0
|
28 - |
|
29 - | app = App()
|
30 - | app.context(Context())
|
31 - |
|
32 - | @app.request_middleware
|
33 - | def request_middleware(request: middleware::Request):
|
34 - | if request.get_header("x-amzn-id") != "secret":
|
35 - | raise middleware.MiddlewareException("Unsupported `x-amz-id` header", 401)
|
36 - |
|
37 - | @app.constrained_http_bound_shapes_operation
|
38 - | def constrained_http_bound_shapes_operation(input: input::ConstrainedHttpBoundShapesOperationInput, ctx: Context) -> output::ConstrainedHttpBoundShapesOperationOutput:
|
39 - | raise NotImplementedError
|
40 - |
|
41 - | @app.constrained_http_payload_bound_shape_operation
|
42 - | def constrained_http_payload_bound_shape_operation(input: input::ConstrainedHttpPayloadBoundShapeOperationInput, ctx: Context) -> output::ConstrainedHttpPayloadBoundShapeOperationOutput:
|
43 - | raise NotImplementedError
|
44 - |
|
45 - | @app.constrained_recursive_shapes_operation
|
46 - | def constrained_recursive_shapes_operation(input: input::ConstrainedRecursiveShapesOperationInput, ctx: Context) -> output::ConstrainedRecursiveShapesOperationOutput:
|
47 - | raise NotImplementedError
|
48 - |
|
49 - | @app.constrained_shapes_only_in_output_operation
|
50 - | def constrained_shapes_only_in_output_operation(input: input::ConstrainedShapesOnlyInOutputOperationInput, ctx: Context) -> output::ConstrainedShapesOnlyInOutputOperationOutput:
|
51 - | raise NotImplementedError
|
52 - |
|
53 - | @app.constrained_shapes_operation
|
54 - | def constrained_shapes_operation(input: input::ConstrainedShapesOperationInput, ctx: Context) -> output::ConstrainedShapesOperationOutput:
|
55 - | raise NotImplementedError
|
56 - |
|
57 - | @app.event_streams_operation
|
58 - | def event_streams_operation(input: input::EventStreamsOperationInput, ctx: Context) -> output::EventStreamsOperationOutput:
|
59 - | raise NotImplementedError
|
60 - |
|
61 - | @app.http_prefix_headers_targeting_length_map_operation
|
62 - | def http_prefix_headers_targeting_length_map_operation(input: input::HttpPrefixHeadersTargetingLengthMapOperationInput, ctx: Context) -> output::HttpPrefixHeadersTargetingLengthMapOperationOutput:
|
63 - | raise NotImplementedError
|
64 - |
|
65 - | @app.non_streaming_blob_operation
|
66 - | def non_streaming_blob_operation(input: input::NonStreamingBlobOperationInput, ctx: Context) -> output::NonStreamingBlobOperationOutput:
|
67 - | raise NotImplementedError
|
68 - |
|
69 - | @app.query_params_targeting_length_map_operation
|
70 - | def query_params_targeting_length_map_operation(input: input::QueryParamsTargetingLengthMapOperationInput, ctx: Context) -> output::QueryParamsTargetingLengthMapOperationOutput:
|
71 - | raise NotImplementedError
|
72 - |
|
73 - | @app.query_params_targeting_map_of_enum_string_operation
|
74 - | def query_params_targeting_map_of_enum_string_operation(input: input::QueryParamsTargetingMapOfEnumStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfEnumStringOperationOutput:
|
75 - | raise NotImplementedError
|
76 - |
|
77 - | @app.query_params_targeting_map_of_length_list_of_pattern_string_operation
|
78 - | def query_params_targeting_map_of_length_list_of_pattern_string_operation(input: input::QueryParamsTargetingMapOfLengthListOfPatternStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfLengthListOfPatternStringOperationOutput:
|
79 - | raise NotImplementedError
|
80 - |
|
81 - | @app.query_params_targeting_map_of_length_pattern_string_operation
|
82 - | def query_params_targeting_map_of_length_pattern_string_operation(input: input::QueryParamsTargetingMapOfLengthPatternStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfLengthPatternStringOperationOutput:
|
83 - | raise NotImplementedError
|
84 - |
|
85 - | @app.query_params_targeting_map_of_length_string_operation
|
86 - | def query_params_targeting_map_of_length_string_operation(input: input::QueryParamsTargetingMapOfLengthStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfLengthStringOperationOutput:
|
87 - | raise NotImplementedError
|
88 - |
|
89 - | @app.query_params_targeting_map_of_list_of_enum_string_operation
|
90 - | def query_params_targeting_map_of_list_of_enum_string_operation(input: input::QueryParamsTargetingMapOfListOfEnumStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfListOfEnumStringOperationOutput:
|
91 - | raise NotImplementedError
|
92 - |
|
93 - | @app.query_params_targeting_map_of_list_of_length_pattern_string_operation
|
94 - | def query_params_targeting_map_of_list_of_length_pattern_string_operation(input: input::QueryParamsTargetingMapOfListOfLengthPatternStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfListOfLengthPatternStringOperationOutput:
|
95 - | raise NotImplementedError
|
96 - |
|
97 - | @app.query_params_targeting_map_of_list_of_length_string_operation
|
98 - | def query_params_targeting_map_of_list_of_length_string_operation(input: input::QueryParamsTargetingMapOfListOfLengthStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfListOfLengthStringOperationOutput:
|
99 - | raise NotImplementedError
|
100 - |
|
101 - | @app.query_params_targeting_map_of_list_of_pattern_string_operation
|
102 - | def query_params_targeting_map_of_list_of_pattern_string_operation(input: input::QueryParamsTargetingMapOfListOfPatternStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfListOfPatternStringOperationOutput:
|
103 - | raise NotImplementedError
|
104 - |
|
105 - | @app.query_params_targeting_map_of_pattern_string_operation
|
106 - | def query_params_targeting_map_of_pattern_string_operation(input: input::QueryParamsTargetingMapOfPatternStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfPatternStringOperationOutput:
|
107 - | raise NotImplementedError
|
108 - |
|
109 - | @app.query_params_targeting_map_of_set_of_length_string_operation
|
110 - | def query_params_targeting_map_of_set_of_length_string_operation(input: input::QueryParamsTargetingMapOfSetOfLengthStringOperationInput, ctx: Context) -> output::QueryParamsTargetingMapOfSetOfLengthStringOperationOutput:
|
111 - | raise NotImplementedError
|
112 - |
|
113 - | @app.streaming_blob_operation
|
114 - | def streaming_blob_operation(input: input::StreamingBlobOperationInput, ctx: Context) -> output::StreamingBlobOperationOutput:
|
115 - | raise NotImplementedError
|
116 - |
|
117 - | app.run()
|
118 - | ```
|
119 - |
|
120 - | Any of operations above can be written as well prepending the `async` keyword and
|
121 - | the Python application will automatically handle it and schedule it on the event loop for you.
|
122 - | """
|
123 - |
|
124 - | def constrained_http_bound_shapes_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedHttpBoundShapesOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.ConstrainedHttpBoundShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedHttpBoundShapesOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedHttpBoundShapesOperationInput], typing.Union[constraints_without_public_constrained_types.output.ConstrainedHttpBoundShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedHttpBoundShapesOperationOutput]]]]) -> None:
|
125 - | """
|
126 - | Method to register `constrained_http_bound_shapes_operation` Python implementation inside the handlers map.
|
127 - | It can be used as a function decorator in Python.
|
128 - | """
|
129 - | ...
|
130 - |
|
131 - |
|
132 - | def constrained_http_payload_bound_shape_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedHttpPayloadBoundShapeOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.ConstrainedHttpPayloadBoundShapeOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedHttpPayloadBoundShapeOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedHttpPayloadBoundShapeOperationInput], typing.Union[constraints_without_public_constrained_types.output.ConstrainedHttpPayloadBoundShapeOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedHttpPayloadBoundShapeOperationOutput]]]]) -> None:
|
133 - | """
|
134 - | Method to register `constrained_http_payload_bound_shape_operation` Python implementation inside the handlers map.
|
135 - | It can be used as a function decorator in Python.
|
136 - | """
|
137 - | ...
|
138 - |
|
139 - |
|
140 - | def constrained_recursive_shapes_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedRecursiveShapesOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.ConstrainedRecursiveShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedRecursiveShapesOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedRecursiveShapesOperationInput], typing.Union[constraints_without_public_constrained_types.output.ConstrainedRecursiveShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedRecursiveShapesOperationOutput]]]]) -> None:
|
141 - | """
|
142 - | Method to register `constrained_recursive_shapes_operation` Python implementation inside the handlers map.
|
143 - | It can be used as a function decorator in Python.
|
144 - | """
|
145 - | ...
|
146 - |
|
147 - |
|
148 - | def constrained_shapes_only_in_output_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedShapesOnlyInOutputOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.ConstrainedShapesOnlyInOutputOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedShapesOnlyInOutputOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedShapesOnlyInOutputOperationInput], typing.Union[constraints_without_public_constrained_types.output.ConstrainedShapesOnlyInOutputOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedShapesOnlyInOutputOperationOutput]]]]) -> None:
|
149 - | """
|
150 - | Method to register `constrained_shapes_only_in_output_operation` Python implementation inside the handlers map.
|
151 - | It can be used as a function decorator in Python.
|
152 - | """
|
153 - | ...
|
154 - |
|
155 - |
|
156 - | def constrained_shapes_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedShapesOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.ConstrainedShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedShapesOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.ConstrainedShapesOperationInput], typing.Union[constraints_without_public_constrained_types.output.ConstrainedShapesOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.ConstrainedShapesOperationOutput]]]]) -> None:
|
157 - | """
|
158 - | Method to register `constrained_shapes_operation` Python implementation inside the handlers map.
|
159 - | It can be used as a function decorator in Python.
|
160 - | """
|
161 - | ...
|
162 - |
|
163 - |
|
164 - | def context(self, context: Ctx) -> None:
|
165 - | """
|
166 - | Register a context object that will be shared between handlers.
|
167 - | """
|
168 - | ...
|
169 - |
|
170 - |
|
171 - | def event_streams_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.EventStreamsOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.EventStreamsOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.EventStreamsOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.EventStreamsOperationInput], typing.Union[constraints_without_public_constrained_types.output.EventStreamsOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.EventStreamsOperationOutput]]]]) -> None:
|
172 - | """
|
173 - | Method to register `event_streams_operation` Python implementation inside the handlers map.
|
174 - | It can be used as a function decorator in Python.
|
175 - | """
|
176 - | ...
|
177 - |
|
178 - |
|
179 - | def http_prefix_headers_targeting_length_map_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.HttpPrefixHeadersTargetingLengthMapOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.HttpPrefixHeadersTargetingLengthMapOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.HttpPrefixHeadersTargetingLengthMapOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.HttpPrefixHeadersTargetingLengthMapOperationInput], typing.Union[constraints_without_public_constrained_types.output.HttpPrefixHeadersTargetingLengthMapOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.HttpPrefixHeadersTargetingLengthMapOperationOutput]]]]) -> None:
|
180 - | """
|
181 - | Method to register `http_prefix_headers_targeting_length_map_operation` Python implementation inside the handlers map.
|
182 - | It can be used as a function decorator in Python.
|
183 - | """
|
184 - | ...
|
185 - |
|
186 - |
|
187 - | def middleware(self, func: typing.Callable[[constraints_without_public_constrained_types.middleware.Request, typing.Callable[[constraints_without_public_constrained_types.middleware.Request], typing.Awaitable[constraints_without_public_constrained_types.middleware.Response]]], typing.Awaitable[constraints_without_public_constrained_types.middleware.Response]]) -> None:
|
188 - | """
|
189 - | Register a Python function to be executed inside a Tower middleware layer.
|
190 - | """
|
191 - | ...
|
192 - |
|
193 - |
|
194 - | def non_streaming_blob_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.NonStreamingBlobOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.NonStreamingBlobOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.NonStreamingBlobOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.NonStreamingBlobOperationInput], typing.Union[constraints_without_public_constrained_types.output.NonStreamingBlobOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.NonStreamingBlobOperationOutput]]]]) -> None:
|
195 - | """
|
196 - | Method to register `non_streaming_blob_operation` Python implementation inside the handlers map.
|
197 - | It can be used as a function decorator in Python.
|
198 - | """
|
199 - | ...
|
200 - |
|
201 - |
|
202 - | def query_params_targeting_length_map_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingLengthMapOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingLengthMapOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingLengthMapOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingLengthMapOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingLengthMapOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingLengthMapOperationOutput]]]]) -> None:
|
203 - | """
|
204 - | Method to register `query_params_targeting_length_map_operation` Python implementation inside the handlers map.
|
205 - | It can be used as a function decorator in Python.
|
206 - | """
|
207 - | ...
|
208 - |
|
209 - |
|
210 - | def query_params_targeting_map_of_enum_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfEnumStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfEnumStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfEnumStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfEnumStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfEnumStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfEnumStringOperationOutput]]]]) -> None:
|
211 - | """
|
212 - | Method to register `query_params_targeting_map_of_enum_string_operation` Python implementation inside the handlers map.
|
213 - | It can be used as a function decorator in Python.
|
214 - | """
|
215 - | ...
|
216 - |
|
217 - |
|
218 - | def query_params_targeting_map_of_length_list_of_pattern_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthListOfPatternStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthListOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthListOfPatternStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthListOfPatternStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthListOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthListOfPatternStringOperationOutput]]]]) -> None:
|
219 - | """
|
220 - | Method to register `query_params_targeting_map_of_length_list_of_pattern_string_operation` Python implementation inside the handlers map.
|
221 - | It can be used as a function decorator in Python.
|
222 - | """
|
223 - | ...
|
224 - |
|
225 - |
|
226 - | def query_params_targeting_map_of_length_pattern_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthPatternStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthPatternStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthPatternStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthPatternStringOperationOutput]]]]) -> None:
|
227 - | """
|
228 - | Method to register `query_params_targeting_map_of_length_pattern_string_operation` Python implementation inside the handlers map.
|
229 - | It can be used as a function decorator in Python.
|
230 - | """
|
231 - | ...
|
232 - |
|
233 - |
|
234 - | def query_params_targeting_map_of_length_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfLengthStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfLengthStringOperationOutput]]]]) -> None:
|
235 - | """
|
236 - | Method to register `query_params_targeting_map_of_length_string_operation` Python implementation inside the handlers map.
|
237 - | It can be used as a function decorator in Python.
|
238 - | """
|
239 - | ...
|
240 - |
|
241 - |
|
242 - | def query_params_targeting_map_of_list_of_enum_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfEnumStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfEnumStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfEnumStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfEnumStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfEnumStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfEnumStringOperationOutput]]]]) -> None:
|
243 - | """
|
244 - | Method to register `query_params_targeting_map_of_list_of_enum_string_operation` Python implementation inside the handlers map.
|
245 - | It can be used as a function decorator in Python.
|
246 - | """
|
247 - | ...
|
248 - |
|
249 - |
|
250 - | def query_params_targeting_map_of_list_of_length_pattern_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfLengthPatternStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthPatternStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfLengthPatternStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthPatternStringOperationOutput]]]]) -> None:
|
251 - | """
|
252 - | Method to register `query_params_targeting_map_of_list_of_length_pattern_string_operation` Python implementation inside the handlers map.
|
253 - | It can be used as a function decorator in Python.
|
254 - | """
|
255 - | ...
|
256 - |
|
257 - |
|
258 - | def query_params_targeting_map_of_list_of_length_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfLengthStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfLengthStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfLengthStringOperationOutput]]]]) -> None:
|
259 - | """
|
260 - | Method to register `query_params_targeting_map_of_list_of_length_string_operation` Python implementation inside the handlers map.
|
261 - | It can be used as a function decorator in Python.
|
262 - | """
|
263 - | ...
|
264 - |
|
265 - |
|
266 - | def query_params_targeting_map_of_list_of_pattern_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfPatternStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfPatternStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfListOfPatternStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfListOfPatternStringOperationOutput]]]]) -> None:
|
267 - | """
|
268 - | Method to register `query_params_targeting_map_of_list_of_pattern_string_operation` Python implementation inside the handlers map.
|
269 - | It can be used as a function decorator in Python.
|
270 - | """
|
271 - | ...
|
272 - |
|
273 - |
|
274 - | def query_params_targeting_map_of_pattern_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfPatternStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfPatternStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfPatternStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfPatternStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfPatternStringOperationOutput]]]]) -> None:
|
275 - | """
|
276 - | Method to register `query_params_targeting_map_of_pattern_string_operation` Python implementation inside the handlers map.
|
277 - | It can be used as a function decorator in Python.
|
278 - | """
|
279 - | ...
|
280 - |
|
281 - |
|
282 - | def query_params_targeting_map_of_set_of_length_string_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfSetOfLengthStringOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfSetOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfSetOfLengthStringOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.QueryParamsTargetingMapOfSetOfLengthStringOperationInput], typing.Union[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfSetOfLengthStringOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.QueryParamsTargetingMapOfSetOfLengthStringOperationOutput]]]]) -> None:
|
283 - | """
|
284 - | Method to register `query_params_targeting_map_of_set_of_length_string_operation` Python implementation inside the handlers map.
|
285 - | It can be used as a function decorator in Python.
|
286 - | """
|
287 - | ...
|
288 - |
|
289 - |
|
290 - | def run(self, address: typing.Optional[str] = ..., port: typing.Optional[int] = ..., backlog: typing.Optional[int] = ..., workers: typing.Optional[int] = ..., tls: typing.Optional[constraints_without_public_constrained_types.tls.TlsConfig] = ...) -> None:
|
291 - | """
|
292 - | Main entrypoint: start the server on multiple workers.
|
293 - | """
|
294 - | ...
|
295 - |
|
296 - |
|
297 - | def run_lambda(self) -> None:
|
298 - | """
|
299 - | Lambda entrypoint: start the server on Lambda.
|
300 - | """
|
301 - | ...
|
302 - |
|
303 - |
|
304 - | def start_worker(self) -> None:
|
305 - | """
|
306 - | Build the service and start a single worker.
|
307 - | """
|
308 - | ...
|
309 - |
|
310 - |
|
311 - | def streaming_blob_operation(self, func: typing.Union[typing.Callable[[constraints_without_public_constrained_types.input.StreamingBlobOperationInput, Ctx], typing.Union[constraints_without_public_constrained_types.output.StreamingBlobOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.StreamingBlobOperationOutput]]], typing.Callable[[constraints_without_public_constrained_types.input.StreamingBlobOperationInput], typing.Union[constraints_without_public_constrained_types.output.StreamingBlobOperationOutput, typing.Awaitable[constraints_without_public_constrained_types.output.StreamingBlobOperationOutput]]]]) -> None:
|
312 - | """
|
313 - | Method to register `streaming_blob_operation` Python implementation inside the handlers map.
|
314 - | It can be used as a function decorator in Python.
|
315 - | """
|
316 - | ...
|
317 - |
|
318 - |
|
319 - | def __init__(self) -> None:
|
320 - | ...
|
321 - |
|
322 - |
|
323 - | CODEGEN_VERSION: str = ...
|