graphscope-flex 0.27.0__5-py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- graphscope/flex/rest/__init__.py +97 -0
- graphscope/flex/rest/api/__init__.py +12 -0
- graphscope/flex/rest/api/alert_api.py +2780 -0
- graphscope/flex/rest/api/data_source_api.py +1173 -0
- graphscope/flex/rest/api/deployment_api.py +528 -0
- graphscope/flex/rest/api/graph_api.py +2803 -0
- graphscope/flex/rest/api/job_api.py +1356 -0
- graphscope/flex/rest/api/service_api.py +1311 -0
- graphscope/flex/rest/api/stored_procedure_api.py +1449 -0
- graphscope/flex/rest/api/utils_api.py +309 -0
- graphscope/flex/rest/api_client.py +759 -0
- graphscope/flex/rest/api_response.py +21 -0
- graphscope/flex/rest/configuration.py +437 -0
- graphscope/flex/rest/exceptions.py +200 -0
- graphscope/flex/rest/models/__init__.py +73 -0
- graphscope/flex/rest/models/base_edge_type.py +102 -0
- graphscope/flex/rest/models/base_edge_type_vertex_type_pair_relations_inner.py +105 -0
- graphscope/flex/rest/models/base_edge_type_vertex_type_pair_relations_inner_x_csr_params.py +98 -0
- graphscope/flex/rest/models/base_property_meta.py +105 -0
- graphscope/flex/rest/models/base_vertex_type.py +96 -0
- graphscope/flex/rest/models/base_vertex_type_x_csr_params.py +88 -0
- graphscope/flex/rest/models/column_mapping.py +94 -0
- graphscope/flex/rest/models/column_mapping_column.py +90 -0
- graphscope/flex/rest/models/create_alert_receiver_request.py +103 -0
- graphscope/flex/rest/models/create_alert_rule_request.py +112 -0
- graphscope/flex/rest/models/create_dataloading_job_response.py +88 -0
- graphscope/flex/rest/models/create_edge_type.py +114 -0
- graphscope/flex/rest/models/create_graph_request.py +106 -0
- graphscope/flex/rest/models/create_graph_response.py +88 -0
- graphscope/flex/rest/models/create_graph_schema_request.py +106 -0
- graphscope/flex/rest/models/create_property_meta.py +100 -0
- graphscope/flex/rest/models/create_stored_proc_request.py +101 -0
- graphscope/flex/rest/models/create_stored_proc_response.py +88 -0
- graphscope/flex/rest/models/create_vertex_type.py +108 -0
- graphscope/flex/rest/models/dataloading_job_config.py +136 -0
- graphscope/flex/rest/models/dataloading_job_config_edges_inner.py +92 -0
- graphscope/flex/rest/models/dataloading_job_config_loading_config.py +104 -0
- graphscope/flex/rest/models/dataloading_job_config_loading_config_format.py +90 -0
- graphscope/flex/rest/models/dataloading_job_config_vertices_inner.py +88 -0
- graphscope/flex/rest/models/edge_mapping.py +122 -0
- graphscope/flex/rest/models/edge_mapping_type_triplet.py +92 -0
- graphscope/flex/rest/models/error.py +90 -0
- graphscope/flex/rest/models/get_alert_message_response.py +123 -0
- graphscope/flex/rest/models/get_alert_receiver_response.py +107 -0
- graphscope/flex/rest/models/get_alert_rule_response.py +114 -0
- graphscope/flex/rest/models/get_edge_type.py +116 -0
- graphscope/flex/rest/models/get_graph_response.py +126 -0
- graphscope/flex/rest/models/get_graph_schema_response.py +106 -0
- graphscope/flex/rest/models/get_property_meta.py +102 -0
- graphscope/flex/rest/models/get_stored_proc_response.py +128 -0
- graphscope/flex/rest/models/get_vertex_type.py +110 -0
- graphscope/flex/rest/models/gs_data_type.py +138 -0
- graphscope/flex/rest/models/job_status.py +107 -0
- graphscope/flex/rest/models/long_text.py +93 -0
- graphscope/flex/rest/models/node_status.py +94 -0
- graphscope/flex/rest/models/parameter.py +94 -0
- graphscope/flex/rest/models/primitive_type.py +95 -0
- graphscope/flex/rest/models/running_deployment_info.py +128 -0
- graphscope/flex/rest/models/running_deployment_status.py +105 -0
- graphscope/flex/rest/models/running_deployment_status_nodes_inner.py +124 -0
- graphscope/flex/rest/models/schema_mapping.py +106 -0
- graphscope/flex/rest/models/service_status.py +105 -0
- graphscope/flex/rest/models/service_status_sdk_endpoints.py +94 -0
- graphscope/flex/rest/models/start_service_request.py +88 -0
- graphscope/flex/rest/models/stored_procedure_meta.py +124 -0
- graphscope/flex/rest/models/string_type.py +92 -0
- graphscope/flex/rest/models/string_type_string.py +124 -0
- graphscope/flex/rest/models/update_alert_message_status_request.py +97 -0
- graphscope/flex/rest/models/update_stored_proc_request.py +88 -0
- graphscope/flex/rest/models/upload_file_response.py +90 -0
- graphscope/flex/rest/models/vertex_mapping.py +100 -0
- graphscope/flex/rest/py.typed +0 -0
- graphscope/flex/rest/rest.py +256 -0
- graphscope_flex-0.27.0.dist-info/METADATA +17 -0
- graphscope_flex-0.27.0.dist-info/RECORD +77 -0
- graphscope_flex-0.27.0.dist-info/WHEEL +6 -0
- graphscope_flex-0.27.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,1311 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
"""
|
4
|
+
GraphScope FLEX HTTP SERVICE API
|
5
|
+
|
6
|
+
This is a specification for GraphScope FLEX HTTP service based on the OpenAPI 3.0 specification. You can find out more details about specification at [doc](https://swagger.io/specification/v3/). Some useful links: - [GraphScope Repository](https://github.com/alibaba/GraphScope) - [The Source API definition for GraphScope Interactive](https://github.com/GraphScope/portal/tree/main/httpservice)
|
7
|
+
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
9
|
+
Contact: graphscope@alibaba-inc.com
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
11
|
+
|
12
|
+
Do not edit the class manually.
|
13
|
+
""" # noqa: E501
|
14
|
+
|
15
|
+
import warnings
|
16
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
17
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
18
|
+
from typing_extensions import Annotated
|
19
|
+
|
20
|
+
from pydantic import StrictStr
|
21
|
+
from typing import Optional
|
22
|
+
from graphscope.flex.rest.models.service_status import ServiceStatus
|
23
|
+
from graphscope.flex.rest.models.start_service_request import StartServiceRequest
|
24
|
+
|
25
|
+
from graphscope.flex.rest.api_client import ApiClient, RequestSerialized
|
26
|
+
from graphscope.flex.rest.api_response import ApiResponse
|
27
|
+
from graphscope.flex.rest.rest import RESTResponseType
|
28
|
+
|
29
|
+
|
30
|
+
class ServiceApi:
|
31
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
32
|
+
Ref: https://openapi-generator.tech
|
33
|
+
|
34
|
+
Do not edit the class manually.
|
35
|
+
"""
|
36
|
+
|
37
|
+
def __init__(self, api_client=None) -> None:
|
38
|
+
if api_client is None:
|
39
|
+
api_client = ApiClient.get_default()
|
40
|
+
self.api_client = api_client
|
41
|
+
|
42
|
+
|
43
|
+
@validate_call
|
44
|
+
def get_service_status_by_id(
|
45
|
+
self,
|
46
|
+
graph_id: StrictStr,
|
47
|
+
_request_timeout: Union[
|
48
|
+
None,
|
49
|
+
Annotated[StrictFloat, Field(gt=0)],
|
50
|
+
Tuple[
|
51
|
+
Annotated[StrictFloat, Field(gt=0)],
|
52
|
+
Annotated[StrictFloat, Field(gt=0)]
|
53
|
+
]
|
54
|
+
] = None,
|
55
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
56
|
+
_content_type: Optional[StrictStr] = None,
|
57
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
58
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
59
|
+
) -> ServiceStatus:
|
60
|
+
"""get_service_status_by_id
|
61
|
+
|
62
|
+
Get service status by graph ID
|
63
|
+
|
64
|
+
:param graph_id: (required)
|
65
|
+
:type graph_id: str
|
66
|
+
:param _request_timeout: timeout setting for this request. If one
|
67
|
+
number provided, it will be total request
|
68
|
+
timeout. It can also be a pair (tuple) of
|
69
|
+
(connection, read) timeouts.
|
70
|
+
:type _request_timeout: int, tuple(int, int), optional
|
71
|
+
:param _request_auth: set to override the auth_settings for an a single
|
72
|
+
request; this effectively ignores the
|
73
|
+
authentication in the spec for a single request.
|
74
|
+
:type _request_auth: dict, optional
|
75
|
+
:param _content_type: force content-type for the request.
|
76
|
+
:type _content_type: str, Optional
|
77
|
+
:param _headers: set to override the headers for a single
|
78
|
+
request; this effectively ignores the headers
|
79
|
+
in the spec for a single request.
|
80
|
+
:type _headers: dict, optional
|
81
|
+
:param _host_index: set to override the host_index for a single
|
82
|
+
request; this effectively ignores the host_index
|
83
|
+
in the spec for a single request.
|
84
|
+
:type _host_index: int, optional
|
85
|
+
:return: Returns the result object.
|
86
|
+
""" # noqa: E501
|
87
|
+
|
88
|
+
_param = self._get_service_status_by_id_serialize(
|
89
|
+
graph_id=graph_id,
|
90
|
+
_request_auth=_request_auth,
|
91
|
+
_content_type=_content_type,
|
92
|
+
_headers=_headers,
|
93
|
+
_host_index=_host_index
|
94
|
+
)
|
95
|
+
|
96
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
97
|
+
'200': "ServiceStatus",
|
98
|
+
'500': "Error",
|
99
|
+
}
|
100
|
+
response_data = self.api_client.call_api(
|
101
|
+
*_param,
|
102
|
+
_request_timeout=_request_timeout
|
103
|
+
)
|
104
|
+
response_data.read()
|
105
|
+
return self.api_client.response_deserialize(
|
106
|
+
response_data=response_data,
|
107
|
+
response_types_map=_response_types_map,
|
108
|
+
).data
|
109
|
+
|
110
|
+
|
111
|
+
@validate_call
|
112
|
+
def get_service_status_by_id_with_http_info(
|
113
|
+
self,
|
114
|
+
graph_id: StrictStr,
|
115
|
+
_request_timeout: Union[
|
116
|
+
None,
|
117
|
+
Annotated[StrictFloat, Field(gt=0)],
|
118
|
+
Tuple[
|
119
|
+
Annotated[StrictFloat, Field(gt=0)],
|
120
|
+
Annotated[StrictFloat, Field(gt=0)]
|
121
|
+
]
|
122
|
+
] = None,
|
123
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
124
|
+
_content_type: Optional[StrictStr] = None,
|
125
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
126
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
127
|
+
) -> ApiResponse[ServiceStatus]:
|
128
|
+
"""get_service_status_by_id
|
129
|
+
|
130
|
+
Get service status by graph ID
|
131
|
+
|
132
|
+
:param graph_id: (required)
|
133
|
+
:type graph_id: str
|
134
|
+
:param _request_timeout: timeout setting for this request. If one
|
135
|
+
number provided, it will be total request
|
136
|
+
timeout. It can also be a pair (tuple) of
|
137
|
+
(connection, read) timeouts.
|
138
|
+
:type _request_timeout: int, tuple(int, int), optional
|
139
|
+
:param _request_auth: set to override the auth_settings for an a single
|
140
|
+
request; this effectively ignores the
|
141
|
+
authentication in the spec for a single request.
|
142
|
+
:type _request_auth: dict, optional
|
143
|
+
:param _content_type: force content-type for the request.
|
144
|
+
:type _content_type: str, Optional
|
145
|
+
:param _headers: set to override the headers for a single
|
146
|
+
request; this effectively ignores the headers
|
147
|
+
in the spec for a single request.
|
148
|
+
:type _headers: dict, optional
|
149
|
+
:param _host_index: set to override the host_index for a single
|
150
|
+
request; this effectively ignores the host_index
|
151
|
+
in the spec for a single request.
|
152
|
+
:type _host_index: int, optional
|
153
|
+
:return: Returns the result object.
|
154
|
+
""" # noqa: E501
|
155
|
+
|
156
|
+
_param = self._get_service_status_by_id_serialize(
|
157
|
+
graph_id=graph_id,
|
158
|
+
_request_auth=_request_auth,
|
159
|
+
_content_type=_content_type,
|
160
|
+
_headers=_headers,
|
161
|
+
_host_index=_host_index
|
162
|
+
)
|
163
|
+
|
164
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
165
|
+
'200': "ServiceStatus",
|
166
|
+
'500': "Error",
|
167
|
+
}
|
168
|
+
response_data = self.api_client.call_api(
|
169
|
+
*_param,
|
170
|
+
_request_timeout=_request_timeout
|
171
|
+
)
|
172
|
+
response_data.read()
|
173
|
+
return self.api_client.response_deserialize(
|
174
|
+
response_data=response_data,
|
175
|
+
response_types_map=_response_types_map,
|
176
|
+
)
|
177
|
+
|
178
|
+
|
179
|
+
@validate_call
|
180
|
+
def get_service_status_by_id_without_preload_content(
|
181
|
+
self,
|
182
|
+
graph_id: StrictStr,
|
183
|
+
_request_timeout: Union[
|
184
|
+
None,
|
185
|
+
Annotated[StrictFloat, Field(gt=0)],
|
186
|
+
Tuple[
|
187
|
+
Annotated[StrictFloat, Field(gt=0)],
|
188
|
+
Annotated[StrictFloat, Field(gt=0)]
|
189
|
+
]
|
190
|
+
] = None,
|
191
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
192
|
+
_content_type: Optional[StrictStr] = None,
|
193
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
194
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
195
|
+
) -> RESTResponseType:
|
196
|
+
"""get_service_status_by_id
|
197
|
+
|
198
|
+
Get service status by graph ID
|
199
|
+
|
200
|
+
:param graph_id: (required)
|
201
|
+
:type graph_id: str
|
202
|
+
:param _request_timeout: timeout setting for this request. If one
|
203
|
+
number provided, it will be total request
|
204
|
+
timeout. It can also be a pair (tuple) of
|
205
|
+
(connection, read) timeouts.
|
206
|
+
:type _request_timeout: int, tuple(int, int), optional
|
207
|
+
:param _request_auth: set to override the auth_settings for an a single
|
208
|
+
request; this effectively ignores the
|
209
|
+
authentication in the spec for a single request.
|
210
|
+
:type _request_auth: dict, optional
|
211
|
+
:param _content_type: force content-type for the request.
|
212
|
+
:type _content_type: str, Optional
|
213
|
+
:param _headers: set to override the headers for a single
|
214
|
+
request; this effectively ignores the headers
|
215
|
+
in the spec for a single request.
|
216
|
+
:type _headers: dict, optional
|
217
|
+
:param _host_index: set to override the host_index for a single
|
218
|
+
request; this effectively ignores the host_index
|
219
|
+
in the spec for a single request.
|
220
|
+
:type _host_index: int, optional
|
221
|
+
:return: Returns the result object.
|
222
|
+
""" # noqa: E501
|
223
|
+
|
224
|
+
_param = self._get_service_status_by_id_serialize(
|
225
|
+
graph_id=graph_id,
|
226
|
+
_request_auth=_request_auth,
|
227
|
+
_content_type=_content_type,
|
228
|
+
_headers=_headers,
|
229
|
+
_host_index=_host_index
|
230
|
+
)
|
231
|
+
|
232
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
233
|
+
'200': "ServiceStatus",
|
234
|
+
'500': "Error",
|
235
|
+
}
|
236
|
+
response_data = self.api_client.call_api(
|
237
|
+
*_param,
|
238
|
+
_request_timeout=_request_timeout
|
239
|
+
)
|
240
|
+
return response_data.response
|
241
|
+
|
242
|
+
|
243
|
+
def _get_service_status_by_id_serialize(
|
244
|
+
self,
|
245
|
+
graph_id,
|
246
|
+
_request_auth,
|
247
|
+
_content_type,
|
248
|
+
_headers,
|
249
|
+
_host_index,
|
250
|
+
) -> RequestSerialized:
|
251
|
+
|
252
|
+
_host = None
|
253
|
+
|
254
|
+
_collection_formats: Dict[str, str] = {
|
255
|
+
}
|
256
|
+
|
257
|
+
_path_params: Dict[str, str] = {}
|
258
|
+
_query_params: List[Tuple[str, str]] = []
|
259
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
260
|
+
_form_params: List[Tuple[str, str]] = []
|
261
|
+
_files: Dict[str, str] = {}
|
262
|
+
_body_params: Optional[bytes] = None
|
263
|
+
|
264
|
+
# process the path parameters
|
265
|
+
if graph_id is not None:
|
266
|
+
_path_params['graph_id'] = graph_id
|
267
|
+
# process the query parameters
|
268
|
+
# process the header parameters
|
269
|
+
# process the form parameters
|
270
|
+
# process the body parameter
|
271
|
+
|
272
|
+
|
273
|
+
# set the HTTP header `Accept`
|
274
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
275
|
+
[
|
276
|
+
'application/json'
|
277
|
+
]
|
278
|
+
)
|
279
|
+
|
280
|
+
|
281
|
+
# authentication setting
|
282
|
+
_auth_settings: List[str] = [
|
283
|
+
]
|
284
|
+
|
285
|
+
return self.api_client.param_serialize(
|
286
|
+
method='GET',
|
287
|
+
resource_path='/api/v1/graph/{graph_id}/service',
|
288
|
+
path_params=_path_params,
|
289
|
+
query_params=_query_params,
|
290
|
+
header_params=_header_params,
|
291
|
+
body=_body_params,
|
292
|
+
post_params=_form_params,
|
293
|
+
files=_files,
|
294
|
+
auth_settings=_auth_settings,
|
295
|
+
collection_formats=_collection_formats,
|
296
|
+
_host=_host,
|
297
|
+
_request_auth=_request_auth
|
298
|
+
)
|
299
|
+
|
300
|
+
|
301
|
+
|
302
|
+
|
303
|
+
@validate_call
|
304
|
+
def list_service_status(
|
305
|
+
self,
|
306
|
+
_request_timeout: Union[
|
307
|
+
None,
|
308
|
+
Annotated[StrictFloat, Field(gt=0)],
|
309
|
+
Tuple[
|
310
|
+
Annotated[StrictFloat, Field(gt=0)],
|
311
|
+
Annotated[StrictFloat, Field(gt=0)]
|
312
|
+
]
|
313
|
+
] = None,
|
314
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
315
|
+
_content_type: Optional[StrictStr] = None,
|
316
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
317
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
318
|
+
) -> List[ServiceStatus]:
|
319
|
+
"""list_service_status
|
320
|
+
|
321
|
+
List all service status
|
322
|
+
|
323
|
+
:param _request_timeout: timeout setting for this request. If one
|
324
|
+
number provided, it will be total request
|
325
|
+
timeout. It can also be a pair (tuple) of
|
326
|
+
(connection, read) timeouts.
|
327
|
+
:type _request_timeout: int, tuple(int, int), optional
|
328
|
+
:param _request_auth: set to override the auth_settings for an a single
|
329
|
+
request; this effectively ignores the
|
330
|
+
authentication in the spec for a single request.
|
331
|
+
:type _request_auth: dict, optional
|
332
|
+
:param _content_type: force content-type for the request.
|
333
|
+
:type _content_type: str, Optional
|
334
|
+
:param _headers: set to override the headers for a single
|
335
|
+
request; this effectively ignores the headers
|
336
|
+
in the spec for a single request.
|
337
|
+
:type _headers: dict, optional
|
338
|
+
:param _host_index: set to override the host_index for a single
|
339
|
+
request; this effectively ignores the host_index
|
340
|
+
in the spec for a single request.
|
341
|
+
:type _host_index: int, optional
|
342
|
+
:return: Returns the result object.
|
343
|
+
""" # noqa: E501
|
344
|
+
|
345
|
+
_param = self._list_service_status_serialize(
|
346
|
+
_request_auth=_request_auth,
|
347
|
+
_content_type=_content_type,
|
348
|
+
_headers=_headers,
|
349
|
+
_host_index=_host_index
|
350
|
+
)
|
351
|
+
|
352
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
353
|
+
'200': "List[ServiceStatus]",
|
354
|
+
'500': "Error",
|
355
|
+
}
|
356
|
+
response_data = self.api_client.call_api(
|
357
|
+
*_param,
|
358
|
+
_request_timeout=_request_timeout
|
359
|
+
)
|
360
|
+
response_data.read()
|
361
|
+
return self.api_client.response_deserialize(
|
362
|
+
response_data=response_data,
|
363
|
+
response_types_map=_response_types_map,
|
364
|
+
).data
|
365
|
+
|
366
|
+
|
367
|
+
@validate_call
|
368
|
+
def list_service_status_with_http_info(
|
369
|
+
self,
|
370
|
+
_request_timeout: Union[
|
371
|
+
None,
|
372
|
+
Annotated[StrictFloat, Field(gt=0)],
|
373
|
+
Tuple[
|
374
|
+
Annotated[StrictFloat, Field(gt=0)],
|
375
|
+
Annotated[StrictFloat, Field(gt=0)]
|
376
|
+
]
|
377
|
+
] = None,
|
378
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
379
|
+
_content_type: Optional[StrictStr] = None,
|
380
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
381
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
382
|
+
) -> ApiResponse[List[ServiceStatus]]:
|
383
|
+
"""list_service_status
|
384
|
+
|
385
|
+
List all service status
|
386
|
+
|
387
|
+
:param _request_timeout: timeout setting for this request. If one
|
388
|
+
number provided, it will be total request
|
389
|
+
timeout. It can also be a pair (tuple) of
|
390
|
+
(connection, read) timeouts.
|
391
|
+
:type _request_timeout: int, tuple(int, int), optional
|
392
|
+
:param _request_auth: set to override the auth_settings for an a single
|
393
|
+
request; this effectively ignores the
|
394
|
+
authentication in the spec for a single request.
|
395
|
+
:type _request_auth: dict, optional
|
396
|
+
:param _content_type: force content-type for the request.
|
397
|
+
:type _content_type: str, Optional
|
398
|
+
:param _headers: set to override the headers for a single
|
399
|
+
request; this effectively ignores the headers
|
400
|
+
in the spec for a single request.
|
401
|
+
:type _headers: dict, optional
|
402
|
+
:param _host_index: set to override the host_index for a single
|
403
|
+
request; this effectively ignores the host_index
|
404
|
+
in the spec for a single request.
|
405
|
+
:type _host_index: int, optional
|
406
|
+
:return: Returns the result object.
|
407
|
+
""" # noqa: E501
|
408
|
+
|
409
|
+
_param = self._list_service_status_serialize(
|
410
|
+
_request_auth=_request_auth,
|
411
|
+
_content_type=_content_type,
|
412
|
+
_headers=_headers,
|
413
|
+
_host_index=_host_index
|
414
|
+
)
|
415
|
+
|
416
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
417
|
+
'200': "List[ServiceStatus]",
|
418
|
+
'500': "Error",
|
419
|
+
}
|
420
|
+
response_data = self.api_client.call_api(
|
421
|
+
*_param,
|
422
|
+
_request_timeout=_request_timeout
|
423
|
+
)
|
424
|
+
response_data.read()
|
425
|
+
return self.api_client.response_deserialize(
|
426
|
+
response_data=response_data,
|
427
|
+
response_types_map=_response_types_map,
|
428
|
+
)
|
429
|
+
|
430
|
+
|
431
|
+
@validate_call
|
432
|
+
def list_service_status_without_preload_content(
|
433
|
+
self,
|
434
|
+
_request_timeout: Union[
|
435
|
+
None,
|
436
|
+
Annotated[StrictFloat, Field(gt=0)],
|
437
|
+
Tuple[
|
438
|
+
Annotated[StrictFloat, Field(gt=0)],
|
439
|
+
Annotated[StrictFloat, Field(gt=0)]
|
440
|
+
]
|
441
|
+
] = None,
|
442
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
443
|
+
_content_type: Optional[StrictStr] = None,
|
444
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
445
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
446
|
+
) -> RESTResponseType:
|
447
|
+
"""list_service_status
|
448
|
+
|
449
|
+
List all service status
|
450
|
+
|
451
|
+
:param _request_timeout: timeout setting for this request. If one
|
452
|
+
number provided, it will be total request
|
453
|
+
timeout. It can also be a pair (tuple) of
|
454
|
+
(connection, read) timeouts.
|
455
|
+
:type _request_timeout: int, tuple(int, int), optional
|
456
|
+
:param _request_auth: set to override the auth_settings for an a single
|
457
|
+
request; this effectively ignores the
|
458
|
+
authentication in the spec for a single request.
|
459
|
+
:type _request_auth: dict, optional
|
460
|
+
:param _content_type: force content-type for the request.
|
461
|
+
:type _content_type: str, Optional
|
462
|
+
:param _headers: set to override the headers for a single
|
463
|
+
request; this effectively ignores the headers
|
464
|
+
in the spec for a single request.
|
465
|
+
:type _headers: dict, optional
|
466
|
+
:param _host_index: set to override the host_index for a single
|
467
|
+
request; this effectively ignores the host_index
|
468
|
+
in the spec for a single request.
|
469
|
+
:type _host_index: int, optional
|
470
|
+
:return: Returns the result object.
|
471
|
+
""" # noqa: E501
|
472
|
+
|
473
|
+
_param = self._list_service_status_serialize(
|
474
|
+
_request_auth=_request_auth,
|
475
|
+
_content_type=_content_type,
|
476
|
+
_headers=_headers,
|
477
|
+
_host_index=_host_index
|
478
|
+
)
|
479
|
+
|
480
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
481
|
+
'200': "List[ServiceStatus]",
|
482
|
+
'500': "Error",
|
483
|
+
}
|
484
|
+
response_data = self.api_client.call_api(
|
485
|
+
*_param,
|
486
|
+
_request_timeout=_request_timeout
|
487
|
+
)
|
488
|
+
return response_data.response
|
489
|
+
|
490
|
+
|
491
|
+
def _list_service_status_serialize(
|
492
|
+
self,
|
493
|
+
_request_auth,
|
494
|
+
_content_type,
|
495
|
+
_headers,
|
496
|
+
_host_index,
|
497
|
+
) -> RequestSerialized:
|
498
|
+
|
499
|
+
_host = None
|
500
|
+
|
501
|
+
_collection_formats: Dict[str, str] = {
|
502
|
+
}
|
503
|
+
|
504
|
+
_path_params: Dict[str, str] = {}
|
505
|
+
_query_params: List[Tuple[str, str]] = []
|
506
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
507
|
+
_form_params: List[Tuple[str, str]] = []
|
508
|
+
_files: Dict[str, str] = {}
|
509
|
+
_body_params: Optional[bytes] = None
|
510
|
+
|
511
|
+
# process the path parameters
|
512
|
+
# process the query parameters
|
513
|
+
# process the header parameters
|
514
|
+
# process the form parameters
|
515
|
+
# process the body parameter
|
516
|
+
|
517
|
+
|
518
|
+
# set the HTTP header `Accept`
|
519
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
520
|
+
[
|
521
|
+
'application/json'
|
522
|
+
]
|
523
|
+
)
|
524
|
+
|
525
|
+
|
526
|
+
# authentication setting
|
527
|
+
_auth_settings: List[str] = [
|
528
|
+
]
|
529
|
+
|
530
|
+
return self.api_client.param_serialize(
|
531
|
+
method='GET',
|
532
|
+
resource_path='/api/v1/service',
|
533
|
+
path_params=_path_params,
|
534
|
+
query_params=_query_params,
|
535
|
+
header_params=_header_params,
|
536
|
+
body=_body_params,
|
537
|
+
post_params=_form_params,
|
538
|
+
files=_files,
|
539
|
+
auth_settings=_auth_settings,
|
540
|
+
collection_formats=_collection_formats,
|
541
|
+
_host=_host,
|
542
|
+
_request_auth=_request_auth
|
543
|
+
)
|
544
|
+
|
545
|
+
|
546
|
+
|
547
|
+
|
548
|
+
@validate_call
|
549
|
+
def restart_service(
|
550
|
+
self,
|
551
|
+
_request_timeout: Union[
|
552
|
+
None,
|
553
|
+
Annotated[StrictFloat, Field(gt=0)],
|
554
|
+
Tuple[
|
555
|
+
Annotated[StrictFloat, Field(gt=0)],
|
556
|
+
Annotated[StrictFloat, Field(gt=0)]
|
557
|
+
]
|
558
|
+
] = None,
|
559
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
560
|
+
_content_type: Optional[StrictStr] = None,
|
561
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
562
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
563
|
+
) -> str:
|
564
|
+
"""restart_service
|
565
|
+
|
566
|
+
Restart current service
|
567
|
+
|
568
|
+
:param _request_timeout: timeout setting for this request. If one
|
569
|
+
number provided, it will be total request
|
570
|
+
timeout. It can also be a pair (tuple) of
|
571
|
+
(connection, read) timeouts.
|
572
|
+
:type _request_timeout: int, tuple(int, int), optional
|
573
|
+
:param _request_auth: set to override the auth_settings for an a single
|
574
|
+
request; this effectively ignores the
|
575
|
+
authentication in the spec for a single request.
|
576
|
+
:type _request_auth: dict, optional
|
577
|
+
:param _content_type: force content-type for the request.
|
578
|
+
:type _content_type: str, Optional
|
579
|
+
:param _headers: set to override the headers for a single
|
580
|
+
request; this effectively ignores the headers
|
581
|
+
in the spec for a single request.
|
582
|
+
:type _headers: dict, optional
|
583
|
+
:param _host_index: set to override the host_index for a single
|
584
|
+
request; this effectively ignores the host_index
|
585
|
+
in the spec for a single request.
|
586
|
+
:type _host_index: int, optional
|
587
|
+
:return: Returns the result object.
|
588
|
+
""" # noqa: E501
|
589
|
+
|
590
|
+
_param = self._restart_service_serialize(
|
591
|
+
_request_auth=_request_auth,
|
592
|
+
_content_type=_content_type,
|
593
|
+
_headers=_headers,
|
594
|
+
_host_index=_host_index
|
595
|
+
)
|
596
|
+
|
597
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
598
|
+
'200': "str",
|
599
|
+
'500': "Error",
|
600
|
+
}
|
601
|
+
response_data = self.api_client.call_api(
|
602
|
+
*_param,
|
603
|
+
_request_timeout=_request_timeout
|
604
|
+
)
|
605
|
+
response_data.read()
|
606
|
+
return self.api_client.response_deserialize(
|
607
|
+
response_data=response_data,
|
608
|
+
response_types_map=_response_types_map,
|
609
|
+
).data
|
610
|
+
|
611
|
+
|
612
|
+
@validate_call
|
613
|
+
def restart_service_with_http_info(
|
614
|
+
self,
|
615
|
+
_request_timeout: Union[
|
616
|
+
None,
|
617
|
+
Annotated[StrictFloat, Field(gt=0)],
|
618
|
+
Tuple[
|
619
|
+
Annotated[StrictFloat, Field(gt=0)],
|
620
|
+
Annotated[StrictFloat, Field(gt=0)]
|
621
|
+
]
|
622
|
+
] = None,
|
623
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
624
|
+
_content_type: Optional[StrictStr] = None,
|
625
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
626
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
627
|
+
) -> ApiResponse[str]:
|
628
|
+
"""restart_service
|
629
|
+
|
630
|
+
Restart current service
|
631
|
+
|
632
|
+
:param _request_timeout: timeout setting for this request. If one
|
633
|
+
number provided, it will be total request
|
634
|
+
timeout. It can also be a pair (tuple) of
|
635
|
+
(connection, read) timeouts.
|
636
|
+
:type _request_timeout: int, tuple(int, int), optional
|
637
|
+
:param _request_auth: set to override the auth_settings for an a single
|
638
|
+
request; this effectively ignores the
|
639
|
+
authentication in the spec for a single request.
|
640
|
+
:type _request_auth: dict, optional
|
641
|
+
:param _content_type: force content-type for the request.
|
642
|
+
:type _content_type: str, Optional
|
643
|
+
:param _headers: set to override the headers for a single
|
644
|
+
request; this effectively ignores the headers
|
645
|
+
in the spec for a single request.
|
646
|
+
:type _headers: dict, optional
|
647
|
+
:param _host_index: set to override the host_index for a single
|
648
|
+
request; this effectively ignores the host_index
|
649
|
+
in the spec for a single request.
|
650
|
+
:type _host_index: int, optional
|
651
|
+
:return: Returns the result object.
|
652
|
+
""" # noqa: E501
|
653
|
+
|
654
|
+
_param = self._restart_service_serialize(
|
655
|
+
_request_auth=_request_auth,
|
656
|
+
_content_type=_content_type,
|
657
|
+
_headers=_headers,
|
658
|
+
_host_index=_host_index
|
659
|
+
)
|
660
|
+
|
661
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
662
|
+
'200': "str",
|
663
|
+
'500': "Error",
|
664
|
+
}
|
665
|
+
response_data = self.api_client.call_api(
|
666
|
+
*_param,
|
667
|
+
_request_timeout=_request_timeout
|
668
|
+
)
|
669
|
+
response_data.read()
|
670
|
+
return self.api_client.response_deserialize(
|
671
|
+
response_data=response_data,
|
672
|
+
response_types_map=_response_types_map,
|
673
|
+
)
|
674
|
+
|
675
|
+
|
676
|
+
@validate_call
|
677
|
+
def restart_service_without_preload_content(
|
678
|
+
self,
|
679
|
+
_request_timeout: Union[
|
680
|
+
None,
|
681
|
+
Annotated[StrictFloat, Field(gt=0)],
|
682
|
+
Tuple[
|
683
|
+
Annotated[StrictFloat, Field(gt=0)],
|
684
|
+
Annotated[StrictFloat, Field(gt=0)]
|
685
|
+
]
|
686
|
+
] = None,
|
687
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
688
|
+
_content_type: Optional[StrictStr] = None,
|
689
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
690
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
691
|
+
) -> RESTResponseType:
|
692
|
+
"""restart_service
|
693
|
+
|
694
|
+
Restart current service
|
695
|
+
|
696
|
+
:param _request_timeout: timeout setting for this request. If one
|
697
|
+
number provided, it will be total request
|
698
|
+
timeout. It can also be a pair (tuple) of
|
699
|
+
(connection, read) timeouts.
|
700
|
+
:type _request_timeout: int, tuple(int, int), optional
|
701
|
+
:param _request_auth: set to override the auth_settings for an a single
|
702
|
+
request; this effectively ignores the
|
703
|
+
authentication in the spec for a single request.
|
704
|
+
:type _request_auth: dict, optional
|
705
|
+
:param _content_type: force content-type for the request.
|
706
|
+
:type _content_type: str, Optional
|
707
|
+
:param _headers: set to override the headers for a single
|
708
|
+
request; this effectively ignores the headers
|
709
|
+
in the spec for a single request.
|
710
|
+
:type _headers: dict, optional
|
711
|
+
:param _host_index: set to override the host_index for a single
|
712
|
+
request; this effectively ignores the host_index
|
713
|
+
in the spec for a single request.
|
714
|
+
:type _host_index: int, optional
|
715
|
+
:return: Returns the result object.
|
716
|
+
""" # noqa: E501
|
717
|
+
|
718
|
+
_param = self._restart_service_serialize(
|
719
|
+
_request_auth=_request_auth,
|
720
|
+
_content_type=_content_type,
|
721
|
+
_headers=_headers,
|
722
|
+
_host_index=_host_index
|
723
|
+
)
|
724
|
+
|
725
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
726
|
+
'200': "str",
|
727
|
+
'500': "Error",
|
728
|
+
}
|
729
|
+
response_data = self.api_client.call_api(
|
730
|
+
*_param,
|
731
|
+
_request_timeout=_request_timeout
|
732
|
+
)
|
733
|
+
return response_data.response
|
734
|
+
|
735
|
+
|
736
|
+
def _restart_service_serialize(
|
737
|
+
self,
|
738
|
+
_request_auth,
|
739
|
+
_content_type,
|
740
|
+
_headers,
|
741
|
+
_host_index,
|
742
|
+
) -> RequestSerialized:
|
743
|
+
|
744
|
+
_host = None
|
745
|
+
|
746
|
+
_collection_formats: Dict[str, str] = {
|
747
|
+
}
|
748
|
+
|
749
|
+
_path_params: Dict[str, str] = {}
|
750
|
+
_query_params: List[Tuple[str, str]] = []
|
751
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
752
|
+
_form_params: List[Tuple[str, str]] = []
|
753
|
+
_files: Dict[str, str] = {}
|
754
|
+
_body_params: Optional[bytes] = None
|
755
|
+
|
756
|
+
# process the path parameters
|
757
|
+
# process the query parameters
|
758
|
+
# process the header parameters
|
759
|
+
# process the form parameters
|
760
|
+
# process the body parameter
|
761
|
+
|
762
|
+
|
763
|
+
# set the HTTP header `Accept`
|
764
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
765
|
+
[
|
766
|
+
'application/json'
|
767
|
+
]
|
768
|
+
)
|
769
|
+
|
770
|
+
|
771
|
+
# authentication setting
|
772
|
+
_auth_settings: List[str] = [
|
773
|
+
]
|
774
|
+
|
775
|
+
return self.api_client.param_serialize(
|
776
|
+
method='POST',
|
777
|
+
resource_path='/api/v1/service/restart',
|
778
|
+
path_params=_path_params,
|
779
|
+
query_params=_query_params,
|
780
|
+
header_params=_header_params,
|
781
|
+
body=_body_params,
|
782
|
+
post_params=_form_params,
|
783
|
+
files=_files,
|
784
|
+
auth_settings=_auth_settings,
|
785
|
+
collection_formats=_collection_formats,
|
786
|
+
_host=_host,
|
787
|
+
_request_auth=_request_auth
|
788
|
+
)
|
789
|
+
|
790
|
+
|
791
|
+
|
792
|
+
|
793
|
+
@validate_call
|
794
|
+
def start_service(
|
795
|
+
self,
|
796
|
+
start_service_request: Optional[StartServiceRequest] = None,
|
797
|
+
_request_timeout: Union[
|
798
|
+
None,
|
799
|
+
Annotated[StrictFloat, Field(gt=0)],
|
800
|
+
Tuple[
|
801
|
+
Annotated[StrictFloat, Field(gt=0)],
|
802
|
+
Annotated[StrictFloat, Field(gt=0)]
|
803
|
+
]
|
804
|
+
] = None,
|
805
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
806
|
+
_content_type: Optional[StrictStr] = None,
|
807
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
808
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
809
|
+
) -> str:
|
810
|
+
"""start_service
|
811
|
+
|
812
|
+
Start service
|
813
|
+
|
814
|
+
:param start_service_request:
|
815
|
+
:type start_service_request: StartServiceRequest
|
816
|
+
:param _request_timeout: timeout setting for this request. If one
|
817
|
+
number provided, it will be total request
|
818
|
+
timeout. It can also be a pair (tuple) of
|
819
|
+
(connection, read) timeouts.
|
820
|
+
:type _request_timeout: int, tuple(int, int), optional
|
821
|
+
:param _request_auth: set to override the auth_settings for an a single
|
822
|
+
request; this effectively ignores the
|
823
|
+
authentication in the spec for a single request.
|
824
|
+
:type _request_auth: dict, optional
|
825
|
+
:param _content_type: force content-type for the request.
|
826
|
+
:type _content_type: str, Optional
|
827
|
+
:param _headers: set to override the headers for a single
|
828
|
+
request; this effectively ignores the headers
|
829
|
+
in the spec for a single request.
|
830
|
+
:type _headers: dict, optional
|
831
|
+
:param _host_index: set to override the host_index for a single
|
832
|
+
request; this effectively ignores the host_index
|
833
|
+
in the spec for a single request.
|
834
|
+
:type _host_index: int, optional
|
835
|
+
:return: Returns the result object.
|
836
|
+
""" # noqa: E501
|
837
|
+
|
838
|
+
_param = self._start_service_serialize(
|
839
|
+
start_service_request=start_service_request,
|
840
|
+
_request_auth=_request_auth,
|
841
|
+
_content_type=_content_type,
|
842
|
+
_headers=_headers,
|
843
|
+
_host_index=_host_index
|
844
|
+
)
|
845
|
+
|
846
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
847
|
+
'200': "str",
|
848
|
+
'400': "Error",
|
849
|
+
'500': "Error",
|
850
|
+
}
|
851
|
+
response_data = self.api_client.call_api(
|
852
|
+
*_param,
|
853
|
+
_request_timeout=_request_timeout
|
854
|
+
)
|
855
|
+
response_data.read()
|
856
|
+
return self.api_client.response_deserialize(
|
857
|
+
response_data=response_data,
|
858
|
+
response_types_map=_response_types_map,
|
859
|
+
).data
|
860
|
+
|
861
|
+
|
862
|
+
@validate_call
|
863
|
+
def start_service_with_http_info(
|
864
|
+
self,
|
865
|
+
start_service_request: Optional[StartServiceRequest] = None,
|
866
|
+
_request_timeout: Union[
|
867
|
+
None,
|
868
|
+
Annotated[StrictFloat, Field(gt=0)],
|
869
|
+
Tuple[
|
870
|
+
Annotated[StrictFloat, Field(gt=0)],
|
871
|
+
Annotated[StrictFloat, Field(gt=0)]
|
872
|
+
]
|
873
|
+
] = None,
|
874
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
875
|
+
_content_type: Optional[StrictStr] = None,
|
876
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
877
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
878
|
+
) -> ApiResponse[str]:
|
879
|
+
"""start_service
|
880
|
+
|
881
|
+
Start service
|
882
|
+
|
883
|
+
:param start_service_request:
|
884
|
+
:type start_service_request: StartServiceRequest
|
885
|
+
:param _request_timeout: timeout setting for this request. If one
|
886
|
+
number provided, it will be total request
|
887
|
+
timeout. It can also be a pair (tuple) of
|
888
|
+
(connection, read) timeouts.
|
889
|
+
:type _request_timeout: int, tuple(int, int), optional
|
890
|
+
:param _request_auth: set to override the auth_settings for an a single
|
891
|
+
request; this effectively ignores the
|
892
|
+
authentication in the spec for a single request.
|
893
|
+
:type _request_auth: dict, optional
|
894
|
+
:param _content_type: force content-type for the request.
|
895
|
+
:type _content_type: str, Optional
|
896
|
+
:param _headers: set to override the headers for a single
|
897
|
+
request; this effectively ignores the headers
|
898
|
+
in the spec for a single request.
|
899
|
+
:type _headers: dict, optional
|
900
|
+
:param _host_index: set to override the host_index for a single
|
901
|
+
request; this effectively ignores the host_index
|
902
|
+
in the spec for a single request.
|
903
|
+
:type _host_index: int, optional
|
904
|
+
:return: Returns the result object.
|
905
|
+
""" # noqa: E501
|
906
|
+
|
907
|
+
_param = self._start_service_serialize(
|
908
|
+
start_service_request=start_service_request,
|
909
|
+
_request_auth=_request_auth,
|
910
|
+
_content_type=_content_type,
|
911
|
+
_headers=_headers,
|
912
|
+
_host_index=_host_index
|
913
|
+
)
|
914
|
+
|
915
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
916
|
+
'200': "str",
|
917
|
+
'400': "Error",
|
918
|
+
'500': "Error",
|
919
|
+
}
|
920
|
+
response_data = self.api_client.call_api(
|
921
|
+
*_param,
|
922
|
+
_request_timeout=_request_timeout
|
923
|
+
)
|
924
|
+
response_data.read()
|
925
|
+
return self.api_client.response_deserialize(
|
926
|
+
response_data=response_data,
|
927
|
+
response_types_map=_response_types_map,
|
928
|
+
)
|
929
|
+
|
930
|
+
|
931
|
+
@validate_call
|
932
|
+
def start_service_without_preload_content(
|
933
|
+
self,
|
934
|
+
start_service_request: Optional[StartServiceRequest] = None,
|
935
|
+
_request_timeout: Union[
|
936
|
+
None,
|
937
|
+
Annotated[StrictFloat, Field(gt=0)],
|
938
|
+
Tuple[
|
939
|
+
Annotated[StrictFloat, Field(gt=0)],
|
940
|
+
Annotated[StrictFloat, Field(gt=0)]
|
941
|
+
]
|
942
|
+
] = None,
|
943
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
944
|
+
_content_type: Optional[StrictStr] = None,
|
945
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
946
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
947
|
+
) -> RESTResponseType:
|
948
|
+
"""start_service
|
949
|
+
|
950
|
+
Start service
|
951
|
+
|
952
|
+
:param start_service_request:
|
953
|
+
:type start_service_request: StartServiceRequest
|
954
|
+
:param _request_timeout: timeout setting for this request. If one
|
955
|
+
number provided, it will be total request
|
956
|
+
timeout. It can also be a pair (tuple) of
|
957
|
+
(connection, read) timeouts.
|
958
|
+
:type _request_timeout: int, tuple(int, int), optional
|
959
|
+
:param _request_auth: set to override the auth_settings for an a single
|
960
|
+
request; this effectively ignores the
|
961
|
+
authentication in the spec for a single request.
|
962
|
+
:type _request_auth: dict, optional
|
963
|
+
:param _content_type: force content-type for the request.
|
964
|
+
:type _content_type: str, Optional
|
965
|
+
:param _headers: set to override the headers for a single
|
966
|
+
request; this effectively ignores the headers
|
967
|
+
in the spec for a single request.
|
968
|
+
:type _headers: dict, optional
|
969
|
+
:param _host_index: set to override the host_index for a single
|
970
|
+
request; this effectively ignores the host_index
|
971
|
+
in the spec for a single request.
|
972
|
+
:type _host_index: int, optional
|
973
|
+
:return: Returns the result object.
|
974
|
+
""" # noqa: E501
|
975
|
+
|
976
|
+
_param = self._start_service_serialize(
|
977
|
+
start_service_request=start_service_request,
|
978
|
+
_request_auth=_request_auth,
|
979
|
+
_content_type=_content_type,
|
980
|
+
_headers=_headers,
|
981
|
+
_host_index=_host_index
|
982
|
+
)
|
983
|
+
|
984
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
985
|
+
'200': "str",
|
986
|
+
'400': "Error",
|
987
|
+
'500': "Error",
|
988
|
+
}
|
989
|
+
response_data = self.api_client.call_api(
|
990
|
+
*_param,
|
991
|
+
_request_timeout=_request_timeout
|
992
|
+
)
|
993
|
+
return response_data.response
|
994
|
+
|
995
|
+
|
996
|
+
def _start_service_serialize(
|
997
|
+
self,
|
998
|
+
start_service_request,
|
999
|
+
_request_auth,
|
1000
|
+
_content_type,
|
1001
|
+
_headers,
|
1002
|
+
_host_index,
|
1003
|
+
) -> RequestSerialized:
|
1004
|
+
|
1005
|
+
_host = None
|
1006
|
+
|
1007
|
+
_collection_formats: Dict[str, str] = {
|
1008
|
+
}
|
1009
|
+
|
1010
|
+
_path_params: Dict[str, str] = {}
|
1011
|
+
_query_params: List[Tuple[str, str]] = []
|
1012
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
1013
|
+
_form_params: List[Tuple[str, str]] = []
|
1014
|
+
_files: Dict[str, str] = {}
|
1015
|
+
_body_params: Optional[bytes] = None
|
1016
|
+
|
1017
|
+
# process the path parameters
|
1018
|
+
# process the query parameters
|
1019
|
+
# process the header parameters
|
1020
|
+
# process the form parameters
|
1021
|
+
# process the body parameter
|
1022
|
+
if start_service_request is not None:
|
1023
|
+
_body_params = start_service_request
|
1024
|
+
|
1025
|
+
|
1026
|
+
# set the HTTP header `Accept`
|
1027
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
1028
|
+
[
|
1029
|
+
'application/json'
|
1030
|
+
]
|
1031
|
+
)
|
1032
|
+
|
1033
|
+
# set the HTTP header `Content-Type`
|
1034
|
+
if _content_type:
|
1035
|
+
_header_params['Content-Type'] = _content_type
|
1036
|
+
else:
|
1037
|
+
_default_content_type = (
|
1038
|
+
self.api_client.select_header_content_type(
|
1039
|
+
[
|
1040
|
+
'application/json'
|
1041
|
+
]
|
1042
|
+
)
|
1043
|
+
)
|
1044
|
+
if _default_content_type is not None:
|
1045
|
+
_header_params['Content-Type'] = _default_content_type
|
1046
|
+
|
1047
|
+
# authentication setting
|
1048
|
+
_auth_settings: List[str] = [
|
1049
|
+
]
|
1050
|
+
|
1051
|
+
return self.api_client.param_serialize(
|
1052
|
+
method='POST',
|
1053
|
+
resource_path='/api/v1/service/start',
|
1054
|
+
path_params=_path_params,
|
1055
|
+
query_params=_query_params,
|
1056
|
+
header_params=_header_params,
|
1057
|
+
body=_body_params,
|
1058
|
+
post_params=_form_params,
|
1059
|
+
files=_files,
|
1060
|
+
auth_settings=_auth_settings,
|
1061
|
+
collection_formats=_collection_formats,
|
1062
|
+
_host=_host,
|
1063
|
+
_request_auth=_request_auth
|
1064
|
+
)
|
1065
|
+
|
1066
|
+
|
1067
|
+
|
1068
|
+
|
1069
|
+
@validate_call
|
1070
|
+
def stop_service(
|
1071
|
+
self,
|
1072
|
+
_request_timeout: Union[
|
1073
|
+
None,
|
1074
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1075
|
+
Tuple[
|
1076
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1077
|
+
Annotated[StrictFloat, Field(gt=0)]
|
1078
|
+
]
|
1079
|
+
] = None,
|
1080
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1081
|
+
_content_type: Optional[StrictStr] = None,
|
1082
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1083
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1084
|
+
) -> str:
|
1085
|
+
"""stop_service
|
1086
|
+
|
1087
|
+
Stop current service
|
1088
|
+
|
1089
|
+
:param _request_timeout: timeout setting for this request. If one
|
1090
|
+
number provided, it will be total request
|
1091
|
+
timeout. It can also be a pair (tuple) of
|
1092
|
+
(connection, read) timeouts.
|
1093
|
+
:type _request_timeout: int, tuple(int, int), optional
|
1094
|
+
:param _request_auth: set to override the auth_settings for an a single
|
1095
|
+
request; this effectively ignores the
|
1096
|
+
authentication in the spec for a single request.
|
1097
|
+
:type _request_auth: dict, optional
|
1098
|
+
:param _content_type: force content-type for the request.
|
1099
|
+
:type _content_type: str, Optional
|
1100
|
+
:param _headers: set to override the headers for a single
|
1101
|
+
request; this effectively ignores the headers
|
1102
|
+
in the spec for a single request.
|
1103
|
+
:type _headers: dict, optional
|
1104
|
+
:param _host_index: set to override the host_index for a single
|
1105
|
+
request; this effectively ignores the host_index
|
1106
|
+
in the spec for a single request.
|
1107
|
+
:type _host_index: int, optional
|
1108
|
+
:return: Returns the result object.
|
1109
|
+
""" # noqa: E501
|
1110
|
+
|
1111
|
+
_param = self._stop_service_serialize(
|
1112
|
+
_request_auth=_request_auth,
|
1113
|
+
_content_type=_content_type,
|
1114
|
+
_headers=_headers,
|
1115
|
+
_host_index=_host_index
|
1116
|
+
)
|
1117
|
+
|
1118
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1119
|
+
'200': "str",
|
1120
|
+
'500': "Error",
|
1121
|
+
}
|
1122
|
+
response_data = self.api_client.call_api(
|
1123
|
+
*_param,
|
1124
|
+
_request_timeout=_request_timeout
|
1125
|
+
)
|
1126
|
+
response_data.read()
|
1127
|
+
return self.api_client.response_deserialize(
|
1128
|
+
response_data=response_data,
|
1129
|
+
response_types_map=_response_types_map,
|
1130
|
+
).data
|
1131
|
+
|
1132
|
+
|
1133
|
+
@validate_call
|
1134
|
+
def stop_service_with_http_info(
|
1135
|
+
self,
|
1136
|
+
_request_timeout: Union[
|
1137
|
+
None,
|
1138
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1139
|
+
Tuple[
|
1140
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1141
|
+
Annotated[StrictFloat, Field(gt=0)]
|
1142
|
+
]
|
1143
|
+
] = None,
|
1144
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1145
|
+
_content_type: Optional[StrictStr] = None,
|
1146
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1147
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1148
|
+
) -> ApiResponse[str]:
|
1149
|
+
"""stop_service
|
1150
|
+
|
1151
|
+
Stop current service
|
1152
|
+
|
1153
|
+
:param _request_timeout: timeout setting for this request. If one
|
1154
|
+
number provided, it will be total request
|
1155
|
+
timeout. It can also be a pair (tuple) of
|
1156
|
+
(connection, read) timeouts.
|
1157
|
+
:type _request_timeout: int, tuple(int, int), optional
|
1158
|
+
:param _request_auth: set to override the auth_settings for an a single
|
1159
|
+
request; this effectively ignores the
|
1160
|
+
authentication in the spec for a single request.
|
1161
|
+
:type _request_auth: dict, optional
|
1162
|
+
:param _content_type: force content-type for the request.
|
1163
|
+
:type _content_type: str, Optional
|
1164
|
+
:param _headers: set to override the headers for a single
|
1165
|
+
request; this effectively ignores the headers
|
1166
|
+
in the spec for a single request.
|
1167
|
+
:type _headers: dict, optional
|
1168
|
+
:param _host_index: set to override the host_index for a single
|
1169
|
+
request; this effectively ignores the host_index
|
1170
|
+
in the spec for a single request.
|
1171
|
+
:type _host_index: int, optional
|
1172
|
+
:return: Returns the result object.
|
1173
|
+
""" # noqa: E501
|
1174
|
+
|
1175
|
+
_param = self._stop_service_serialize(
|
1176
|
+
_request_auth=_request_auth,
|
1177
|
+
_content_type=_content_type,
|
1178
|
+
_headers=_headers,
|
1179
|
+
_host_index=_host_index
|
1180
|
+
)
|
1181
|
+
|
1182
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1183
|
+
'200': "str",
|
1184
|
+
'500': "Error",
|
1185
|
+
}
|
1186
|
+
response_data = self.api_client.call_api(
|
1187
|
+
*_param,
|
1188
|
+
_request_timeout=_request_timeout
|
1189
|
+
)
|
1190
|
+
response_data.read()
|
1191
|
+
return self.api_client.response_deserialize(
|
1192
|
+
response_data=response_data,
|
1193
|
+
response_types_map=_response_types_map,
|
1194
|
+
)
|
1195
|
+
|
1196
|
+
|
1197
|
+
@validate_call
|
1198
|
+
def stop_service_without_preload_content(
|
1199
|
+
self,
|
1200
|
+
_request_timeout: Union[
|
1201
|
+
None,
|
1202
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1203
|
+
Tuple[
|
1204
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1205
|
+
Annotated[StrictFloat, Field(gt=0)]
|
1206
|
+
]
|
1207
|
+
] = None,
|
1208
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1209
|
+
_content_type: Optional[StrictStr] = None,
|
1210
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1211
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1212
|
+
) -> RESTResponseType:
|
1213
|
+
"""stop_service
|
1214
|
+
|
1215
|
+
Stop current service
|
1216
|
+
|
1217
|
+
:param _request_timeout: timeout setting for this request. If one
|
1218
|
+
number provided, it will be total request
|
1219
|
+
timeout. It can also be a pair (tuple) of
|
1220
|
+
(connection, read) timeouts.
|
1221
|
+
:type _request_timeout: int, tuple(int, int), optional
|
1222
|
+
:param _request_auth: set to override the auth_settings for an a single
|
1223
|
+
request; this effectively ignores the
|
1224
|
+
authentication in the spec for a single request.
|
1225
|
+
:type _request_auth: dict, optional
|
1226
|
+
:param _content_type: force content-type for the request.
|
1227
|
+
:type _content_type: str, Optional
|
1228
|
+
:param _headers: set to override the headers for a single
|
1229
|
+
request; this effectively ignores the headers
|
1230
|
+
in the spec for a single request.
|
1231
|
+
:type _headers: dict, optional
|
1232
|
+
:param _host_index: set to override the host_index for a single
|
1233
|
+
request; this effectively ignores the host_index
|
1234
|
+
in the spec for a single request.
|
1235
|
+
:type _host_index: int, optional
|
1236
|
+
:return: Returns the result object.
|
1237
|
+
""" # noqa: E501
|
1238
|
+
|
1239
|
+
_param = self._stop_service_serialize(
|
1240
|
+
_request_auth=_request_auth,
|
1241
|
+
_content_type=_content_type,
|
1242
|
+
_headers=_headers,
|
1243
|
+
_host_index=_host_index
|
1244
|
+
)
|
1245
|
+
|
1246
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1247
|
+
'200': "str",
|
1248
|
+
'500': "Error",
|
1249
|
+
}
|
1250
|
+
response_data = self.api_client.call_api(
|
1251
|
+
*_param,
|
1252
|
+
_request_timeout=_request_timeout
|
1253
|
+
)
|
1254
|
+
return response_data.response
|
1255
|
+
|
1256
|
+
|
1257
|
+
def _stop_service_serialize(
|
1258
|
+
self,
|
1259
|
+
_request_auth,
|
1260
|
+
_content_type,
|
1261
|
+
_headers,
|
1262
|
+
_host_index,
|
1263
|
+
) -> RequestSerialized:
|
1264
|
+
|
1265
|
+
_host = None
|
1266
|
+
|
1267
|
+
_collection_formats: Dict[str, str] = {
|
1268
|
+
}
|
1269
|
+
|
1270
|
+
_path_params: Dict[str, str] = {}
|
1271
|
+
_query_params: List[Tuple[str, str]] = []
|
1272
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
1273
|
+
_form_params: List[Tuple[str, str]] = []
|
1274
|
+
_files: Dict[str, str] = {}
|
1275
|
+
_body_params: Optional[bytes] = None
|
1276
|
+
|
1277
|
+
# process the path parameters
|
1278
|
+
# process the query parameters
|
1279
|
+
# process the header parameters
|
1280
|
+
# process the form parameters
|
1281
|
+
# process the body parameter
|
1282
|
+
|
1283
|
+
|
1284
|
+
# set the HTTP header `Accept`
|
1285
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
1286
|
+
[
|
1287
|
+
'application/json'
|
1288
|
+
]
|
1289
|
+
)
|
1290
|
+
|
1291
|
+
|
1292
|
+
# authentication setting
|
1293
|
+
_auth_settings: List[str] = [
|
1294
|
+
]
|
1295
|
+
|
1296
|
+
return self.api_client.param_serialize(
|
1297
|
+
method='POST',
|
1298
|
+
resource_path='/api/v1/service/stop',
|
1299
|
+
path_params=_path_params,
|
1300
|
+
query_params=_query_params,
|
1301
|
+
header_params=_header_params,
|
1302
|
+
body=_body_params,
|
1303
|
+
post_params=_form_params,
|
1304
|
+
files=_files,
|
1305
|
+
auth_settings=_auth_settings,
|
1306
|
+
collection_formats=_collection_formats,
|
1307
|
+
_host=_host,
|
1308
|
+
_request_auth=_request_auth
|
1309
|
+
)
|
1310
|
+
|
1311
|
+
|