lightning-sdk 2025.8.6rc0__py3-none-any.whl → 2025.8.6rc2__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.
- lightning_sdk/__init__.py +1 -1
- lightning_sdk/api/llm_api.py +48 -0
- lightning_sdk/lightning_cloud/login.py +1 -0
- lightning_sdk/lightning_cloud/openapi/__init__.py +15 -23
- lightning_sdk/lightning_cloud/openapi/api/__init__.py +1 -0
- lightning_sdk/lightning_cloud/openapi/api/assistants_service_api.py +5 -1
- lightning_sdk/lightning_cloud/openapi/api/cloud_space_service_api.py +228 -1
- lightning_sdk/lightning_cloud/openapi/api/endpoint_service_api.py +126 -2129
- lightning_sdk/lightning_cloud/openapi/api/k8_s_cluster_service_api.py +625 -0
- lightning_sdk/lightning_cloud/openapi/api/storage_service_api.py +5 -1
- lightning_sdk/lightning_cloud/openapi/models/__init__.py +14 -23
- lightning_sdk/lightning_cloud/openapi/models/cluster_id_metrics_body.py +175 -0
- lightning_sdk/lightning_cloud/openapi/models/orgs_id_body.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/projects_id_body.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_space.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_space_transfer_metadata.py +201 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_cloudflare_v1.py +29 -3
- lightning_sdk/lightning_cloud/openapi/models/{v1_complete_upload_service_execution_artifact_response.py → v1_complete_running_cloud_space_instance_transfer_response.py} +6 -6
- lightning_sdk/lightning_cloud/openapi/models/v1_container_metrics.py +461 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_filesystem_metrics.py +227 -0
- lightning_sdk/lightning_cloud/openapi/models/{v1_list_file_endpoints_response.py → v1_list_container_metrics_response.py} +23 -23
- lightning_sdk/lightning_cloud/openapi/models/{service_artifact_artifact_kind.py → v1_list_node_file_system_metrics_response.py} +6 -13
- lightning_sdk/lightning_cloud/openapi/models/{v1_upload_service_execution_artifact_parts_response.py → v1_list_node_metrics_response.py} +23 -23
- lightning_sdk/lightning_cloud/openapi/models/v1_list_pod_metrics_response.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_managed_model.py +79 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_node_metrics.py +357 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_organization.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_pod_metrics.py +435 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_project_settings.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/{v1_delete_service_execution_response.py → v1_report_k8s_cluster_metrics_response.py} +6 -6
- lightning_sdk/lightning_cloud/openapi/models/{command_argument_command_argument_type.py → v1_request_cloud_space_access_response.py} +6 -12
- lightning_sdk/lightning_cloud/openapi/models/v1_update_cloud_space_instance_config_request.py +331 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_user_features.py +157 -53
- lightning_sdk/lightning_cloud/utils/data_connection.py +56 -1
- lightning_sdk/llm/llm.py +5 -15
- lightning_sdk/llm/public_assistants.py +17 -0
- lightning_sdk/services/file_endpoint.py +3 -4
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/METADATA +1 -1
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/RECORD +43 -51
- lightning_sdk/lightning_cloud/openapi/models/fileendpoints_id_body.py +0 -409
- lightning_sdk/lightning_cloud/openapi/models/id_complete_body.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/id_storage_body.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/id_uploads_body1.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/project_id_fileendpoints_body.py +0 -357
- lightning_sdk/lightning_cloud/openapi/models/project_id_serviceexecution_body.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/serviceexecution_id_body.py +0 -331
- lightning_sdk/lightning_cloud/openapi/models/v1_command_argument.py +0 -305
- lightning_sdk/lightning_cloud/openapi/models/v1_delete_file_endpoint_response.py +0 -149
- lightning_sdk/lightning_cloud/openapi/models/v1_download_service_execution_artifact_response.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/v1_file_endpoint.py +0 -461
- lightning_sdk/lightning_cloud/openapi/models/v1_get_service_execution_status_response.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/v1_list_service_execution_lightningapp_instances_response.py +0 -175
- lightning_sdk/lightning_cloud/openapi/models/v1_list_service_executions_response.py +0 -123
- lightning_sdk/lightning_cloud/openapi/models/v1_service_artifact.py +0 -201
- lightning_sdk/lightning_cloud/openapi/models/v1_service_execution.py +0 -383
- lightning_sdk/lightning_cloud/openapi/models/v1_upload_service_execution_artifact_response.py +0 -149
- lightning_sdk/llm/public_assistants.json +0 -34
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/LICENSE +0 -0
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/WHEEL +0 -0
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/entry_points.txt +0 -0
- {lightning_sdk-2025.8.6rc0.dist-info → lightning_sdk-2025.8.6rc2.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,625 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
external/v1/auth_service.proto
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
|
|
7
|
+
|
|
8
|
+
OpenAPI spec version: version not set
|
|
9
|
+
|
|
10
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
|
11
|
+
|
|
12
|
+
NOTE
|
|
13
|
+
----
|
|
14
|
+
standard swagger-codegen-cli for this python client has been modified
|
|
15
|
+
by custom templates. The purpose of these templates is to include
|
|
16
|
+
typing information in the API and Model code. Please refer to the
|
|
17
|
+
main grid repository for more info
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
from __future__ import absolute_import
|
|
21
|
+
|
|
22
|
+
import re # noqa: F401
|
|
23
|
+
from typing import TYPE_CHECKING, Any
|
|
24
|
+
|
|
25
|
+
# python 2 and python 3 compatibility library
|
|
26
|
+
import six
|
|
27
|
+
|
|
28
|
+
from lightning_sdk.lightning_cloud.openapi.api_client import ApiClient
|
|
29
|
+
|
|
30
|
+
if TYPE_CHECKING:
|
|
31
|
+
from datetime import datetime
|
|
32
|
+
from lightning_sdk.lightning_cloud.openapi.models import *
|
|
33
|
+
|
|
34
|
+
class K8SClusterServiceApi(object):
|
|
35
|
+
"""NOTE: This class is auto generated by the swagger code generator program.
|
|
36
|
+
|
|
37
|
+
Do not edit the class manually.
|
|
38
|
+
Ref: https://github.com/swagger-api/swagger-codegen
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
def __init__(self, api_client=None):
|
|
42
|
+
if api_client is None:
|
|
43
|
+
api_client = ApiClient()
|
|
44
|
+
self.api_client = api_client
|
|
45
|
+
|
|
46
|
+
def k8_s_cluster_service_list_container_metrics(self, project_id: 'str', cluster_id: 'str', pod_id: 'str', container_id: 'str', **kwargs) -> 'V1ListContainerMetricsResponse': # noqa: E501
|
|
47
|
+
"""k8_s_cluster_service_list_container_metrics # noqa: E501
|
|
48
|
+
|
|
49
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
50
|
+
asynchronous HTTP request, please pass async_req=True
|
|
51
|
+
>>> thread = api.k8_s_cluster_service_list_container_metrics(project_id, cluster_id, pod_id, container_id, async_req=True)
|
|
52
|
+
>>> result = thread.get()
|
|
53
|
+
|
|
54
|
+
:param async_req bool
|
|
55
|
+
:param str project_id: (required)
|
|
56
|
+
:param str cluster_id: (required)
|
|
57
|
+
:param str pod_id: (required)
|
|
58
|
+
:param str container_id: (required)
|
|
59
|
+
:param datetime start: Date range.
|
|
60
|
+
:param datetime end:
|
|
61
|
+
:return: V1ListContainerMetricsResponse
|
|
62
|
+
If the method is called asynchronously,
|
|
63
|
+
returns the request thread.
|
|
64
|
+
"""
|
|
65
|
+
kwargs['_return_http_data_only'] = True
|
|
66
|
+
if kwargs.get('async_req'):
|
|
67
|
+
return self.k8_s_cluster_service_list_container_metrics_with_http_info(project_id, cluster_id, pod_id, container_id, **kwargs) # noqa: E501
|
|
68
|
+
else:
|
|
69
|
+
(data) = self.k8_s_cluster_service_list_container_metrics_with_http_info(project_id, cluster_id, pod_id, container_id, **kwargs) # noqa: E501
|
|
70
|
+
return data
|
|
71
|
+
|
|
72
|
+
def k8_s_cluster_service_list_container_metrics_with_http_info(self, project_id: 'str', cluster_id: 'str', pod_id: 'str', container_id: 'str', **kwargs) -> 'V1ListContainerMetricsResponse': # noqa: E501
|
|
73
|
+
"""k8_s_cluster_service_list_container_metrics # noqa: E501
|
|
74
|
+
|
|
75
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
76
|
+
asynchronous HTTP request, please pass async_req=True
|
|
77
|
+
>>> thread = api.k8_s_cluster_service_list_container_metrics_with_http_info(project_id, cluster_id, pod_id, container_id, async_req=True)
|
|
78
|
+
>>> result = thread.get()
|
|
79
|
+
|
|
80
|
+
:param async_req bool
|
|
81
|
+
:param str project_id: (required)
|
|
82
|
+
:param str cluster_id: (required)
|
|
83
|
+
:param str pod_id: (required)
|
|
84
|
+
:param str container_id: (required)
|
|
85
|
+
:param datetime start: Date range.
|
|
86
|
+
:param datetime end:
|
|
87
|
+
:return: V1ListContainerMetricsResponse
|
|
88
|
+
If the method is called asynchronously,
|
|
89
|
+
returns the request thread.
|
|
90
|
+
"""
|
|
91
|
+
|
|
92
|
+
all_params = ['project_id', 'cluster_id', 'pod_id', 'container_id', 'start', 'end'] # noqa: E501
|
|
93
|
+
all_params.append('async_req')
|
|
94
|
+
all_params.append('_return_http_data_only')
|
|
95
|
+
all_params.append('_preload_content')
|
|
96
|
+
all_params.append('_request_timeout')
|
|
97
|
+
|
|
98
|
+
params = locals()
|
|
99
|
+
for key, val in six.iteritems(params['kwargs']):
|
|
100
|
+
if key not in all_params:
|
|
101
|
+
raise TypeError(
|
|
102
|
+
"Got an unexpected keyword argument '%s'"
|
|
103
|
+
" to method k8_s_cluster_service_list_container_metrics" % key
|
|
104
|
+
)
|
|
105
|
+
params[key] = val
|
|
106
|
+
del params['kwargs']
|
|
107
|
+
# verify the required parameter 'project_id' is set
|
|
108
|
+
if ('project_id' not in params or
|
|
109
|
+
params['project_id'] is None):
|
|
110
|
+
raise ValueError("Missing the required parameter `project_id` when calling `k8_s_cluster_service_list_container_metrics`") # noqa: E501
|
|
111
|
+
# verify the required parameter 'cluster_id' is set
|
|
112
|
+
if ('cluster_id' not in params or
|
|
113
|
+
params['cluster_id'] is None):
|
|
114
|
+
raise ValueError("Missing the required parameter `cluster_id` when calling `k8_s_cluster_service_list_container_metrics`") # noqa: E501
|
|
115
|
+
# verify the required parameter 'pod_id' is set
|
|
116
|
+
if ('pod_id' not in params or
|
|
117
|
+
params['pod_id'] is None):
|
|
118
|
+
raise ValueError("Missing the required parameter `pod_id` when calling `k8_s_cluster_service_list_container_metrics`") # noqa: E501
|
|
119
|
+
# verify the required parameter 'container_id' is set
|
|
120
|
+
if ('container_id' not in params or
|
|
121
|
+
params['container_id'] is None):
|
|
122
|
+
raise ValueError("Missing the required parameter `container_id` when calling `k8_s_cluster_service_list_container_metrics`") # noqa: E501
|
|
123
|
+
|
|
124
|
+
collection_formats = {}
|
|
125
|
+
|
|
126
|
+
path_params = {}
|
|
127
|
+
if 'project_id' in params:
|
|
128
|
+
path_params['projectId'] = params['project_id'] # noqa: E501
|
|
129
|
+
if 'cluster_id' in params:
|
|
130
|
+
path_params['clusterId'] = params['cluster_id'] # noqa: E501
|
|
131
|
+
if 'pod_id' in params:
|
|
132
|
+
path_params['podId'] = params['pod_id'] # noqa: E501
|
|
133
|
+
if 'container_id' in params:
|
|
134
|
+
path_params['containerId'] = params['container_id'] # noqa: E501
|
|
135
|
+
|
|
136
|
+
query_params = []
|
|
137
|
+
if 'start' in params:
|
|
138
|
+
query_params.append(('start', params['start'])) # noqa: E501
|
|
139
|
+
if 'end' in params:
|
|
140
|
+
query_params.append(('end', params['end'])) # noqa: E501
|
|
141
|
+
|
|
142
|
+
header_params = {}
|
|
143
|
+
|
|
144
|
+
form_params = []
|
|
145
|
+
local_var_files = {}
|
|
146
|
+
|
|
147
|
+
body_params = None
|
|
148
|
+
# HTTP header `Accept`
|
|
149
|
+
header_params['Accept'] = self.api_client.select_header_accept(
|
|
150
|
+
['application/json']) # noqa: E501
|
|
151
|
+
|
|
152
|
+
# Authentication setting
|
|
153
|
+
auth_settings = [] # noqa: E501
|
|
154
|
+
|
|
155
|
+
return self.api_client.call_api(
|
|
156
|
+
'/v1/projects/{projectId}/clusters/{clusterId}/metrics/pods/{podId}/containers/{containerId}', 'GET',
|
|
157
|
+
path_params,
|
|
158
|
+
query_params,
|
|
159
|
+
header_params,
|
|
160
|
+
body=body_params,
|
|
161
|
+
post_params=form_params,
|
|
162
|
+
files=local_var_files,
|
|
163
|
+
response_type='V1ListContainerMetricsResponse', # noqa: E501
|
|
164
|
+
auth_settings=auth_settings,
|
|
165
|
+
async_req=params.get('async_req'),
|
|
166
|
+
_return_http_data_only=params.get('_return_http_data_only'),
|
|
167
|
+
_preload_content=params.get('_preload_content', True),
|
|
168
|
+
_request_timeout=params.get('_request_timeout'),
|
|
169
|
+
collection_formats=collection_formats)
|
|
170
|
+
|
|
171
|
+
def k8_s_cluster_service_list_node_file_system_metrics(self, project_id: 'str', cluster_id: 'str', node_name: 'str', **kwargs) -> 'V1ListNodeFileSystemMetricsResponse': # noqa: E501
|
|
172
|
+
"""k8_s_cluster_service_list_node_file_system_metrics # noqa: E501
|
|
173
|
+
|
|
174
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
175
|
+
asynchronous HTTP request, please pass async_req=True
|
|
176
|
+
>>> thread = api.k8_s_cluster_service_list_node_file_system_metrics(project_id, cluster_id, node_name, async_req=True)
|
|
177
|
+
>>> result = thread.get()
|
|
178
|
+
|
|
179
|
+
:param async_req bool
|
|
180
|
+
:param str project_id: (required)
|
|
181
|
+
:param str cluster_id: (required)
|
|
182
|
+
:param str node_name: (required)
|
|
183
|
+
:param datetime start: Date range.
|
|
184
|
+
:param datetime end:
|
|
185
|
+
:return: V1ListNodeFileSystemMetricsResponse
|
|
186
|
+
If the method is called asynchronously,
|
|
187
|
+
returns the request thread.
|
|
188
|
+
"""
|
|
189
|
+
kwargs['_return_http_data_only'] = True
|
|
190
|
+
if kwargs.get('async_req'):
|
|
191
|
+
return self.k8_s_cluster_service_list_node_file_system_metrics_with_http_info(project_id, cluster_id, node_name, **kwargs) # noqa: E501
|
|
192
|
+
else:
|
|
193
|
+
(data) = self.k8_s_cluster_service_list_node_file_system_metrics_with_http_info(project_id, cluster_id, node_name, **kwargs) # noqa: E501
|
|
194
|
+
return data
|
|
195
|
+
|
|
196
|
+
def k8_s_cluster_service_list_node_file_system_metrics_with_http_info(self, project_id: 'str', cluster_id: 'str', node_name: 'str', **kwargs) -> 'V1ListNodeFileSystemMetricsResponse': # noqa: E501
|
|
197
|
+
"""k8_s_cluster_service_list_node_file_system_metrics # noqa: E501
|
|
198
|
+
|
|
199
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
200
|
+
asynchronous HTTP request, please pass async_req=True
|
|
201
|
+
>>> thread = api.k8_s_cluster_service_list_node_file_system_metrics_with_http_info(project_id, cluster_id, node_name, async_req=True)
|
|
202
|
+
>>> result = thread.get()
|
|
203
|
+
|
|
204
|
+
:param async_req bool
|
|
205
|
+
:param str project_id: (required)
|
|
206
|
+
:param str cluster_id: (required)
|
|
207
|
+
:param str node_name: (required)
|
|
208
|
+
:param datetime start: Date range.
|
|
209
|
+
:param datetime end:
|
|
210
|
+
:return: V1ListNodeFileSystemMetricsResponse
|
|
211
|
+
If the method is called asynchronously,
|
|
212
|
+
returns the request thread.
|
|
213
|
+
"""
|
|
214
|
+
|
|
215
|
+
all_params = ['project_id', 'cluster_id', 'node_name', 'start', 'end'] # noqa: E501
|
|
216
|
+
all_params.append('async_req')
|
|
217
|
+
all_params.append('_return_http_data_only')
|
|
218
|
+
all_params.append('_preload_content')
|
|
219
|
+
all_params.append('_request_timeout')
|
|
220
|
+
|
|
221
|
+
params = locals()
|
|
222
|
+
for key, val in six.iteritems(params['kwargs']):
|
|
223
|
+
if key not in all_params:
|
|
224
|
+
raise TypeError(
|
|
225
|
+
"Got an unexpected keyword argument '%s'"
|
|
226
|
+
" to method k8_s_cluster_service_list_node_file_system_metrics" % key
|
|
227
|
+
)
|
|
228
|
+
params[key] = val
|
|
229
|
+
del params['kwargs']
|
|
230
|
+
# verify the required parameter 'project_id' is set
|
|
231
|
+
if ('project_id' not in params or
|
|
232
|
+
params['project_id'] is None):
|
|
233
|
+
raise ValueError("Missing the required parameter `project_id` when calling `k8_s_cluster_service_list_node_file_system_metrics`") # noqa: E501
|
|
234
|
+
# verify the required parameter 'cluster_id' is set
|
|
235
|
+
if ('cluster_id' not in params or
|
|
236
|
+
params['cluster_id'] is None):
|
|
237
|
+
raise ValueError("Missing the required parameter `cluster_id` when calling `k8_s_cluster_service_list_node_file_system_metrics`") # noqa: E501
|
|
238
|
+
# verify the required parameter 'node_name' is set
|
|
239
|
+
if ('node_name' not in params or
|
|
240
|
+
params['node_name'] is None):
|
|
241
|
+
raise ValueError("Missing the required parameter `node_name` when calling `k8_s_cluster_service_list_node_file_system_metrics`") # noqa: E501
|
|
242
|
+
|
|
243
|
+
collection_formats = {}
|
|
244
|
+
|
|
245
|
+
path_params = {}
|
|
246
|
+
if 'project_id' in params:
|
|
247
|
+
path_params['projectId'] = params['project_id'] # noqa: E501
|
|
248
|
+
if 'cluster_id' in params:
|
|
249
|
+
path_params['clusterId'] = params['cluster_id'] # noqa: E501
|
|
250
|
+
if 'node_name' in params:
|
|
251
|
+
path_params['nodeName'] = params['node_name'] # noqa: E501
|
|
252
|
+
|
|
253
|
+
query_params = []
|
|
254
|
+
if 'start' in params:
|
|
255
|
+
query_params.append(('start', params['start'])) # noqa: E501
|
|
256
|
+
if 'end' in params:
|
|
257
|
+
query_params.append(('end', params['end'])) # noqa: E501
|
|
258
|
+
|
|
259
|
+
header_params = {}
|
|
260
|
+
|
|
261
|
+
form_params = []
|
|
262
|
+
local_var_files = {}
|
|
263
|
+
|
|
264
|
+
body_params = None
|
|
265
|
+
# HTTP header `Accept`
|
|
266
|
+
header_params['Accept'] = self.api_client.select_header_accept(
|
|
267
|
+
['application/json']) # noqa: E501
|
|
268
|
+
|
|
269
|
+
# Authentication setting
|
|
270
|
+
auth_settings = [] # noqa: E501
|
|
271
|
+
|
|
272
|
+
return self.api_client.call_api(
|
|
273
|
+
'/v1/projects/{projectId}/clusters/{clusterId}/metrics-filesystem/nodes/{nodeName}', 'GET',
|
|
274
|
+
path_params,
|
|
275
|
+
query_params,
|
|
276
|
+
header_params,
|
|
277
|
+
body=body_params,
|
|
278
|
+
post_params=form_params,
|
|
279
|
+
files=local_var_files,
|
|
280
|
+
response_type='V1ListNodeFileSystemMetricsResponse', # noqa: E501
|
|
281
|
+
auth_settings=auth_settings,
|
|
282
|
+
async_req=params.get('async_req'),
|
|
283
|
+
_return_http_data_only=params.get('_return_http_data_only'),
|
|
284
|
+
_preload_content=params.get('_preload_content', True),
|
|
285
|
+
_request_timeout=params.get('_request_timeout'),
|
|
286
|
+
collection_formats=collection_formats)
|
|
287
|
+
|
|
288
|
+
def k8_s_cluster_service_list_node_metrics(self, project_id: 'str', cluster_id: 'str', node_name: 'str', **kwargs) -> 'V1ListNodeMetricsResponse': # noqa: E501
|
|
289
|
+
"""k8_s_cluster_service_list_node_metrics # noqa: E501
|
|
290
|
+
|
|
291
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
292
|
+
asynchronous HTTP request, please pass async_req=True
|
|
293
|
+
>>> thread = api.k8_s_cluster_service_list_node_metrics(project_id, cluster_id, node_name, async_req=True)
|
|
294
|
+
>>> result = thread.get()
|
|
295
|
+
|
|
296
|
+
:param async_req bool
|
|
297
|
+
:param str project_id: (required)
|
|
298
|
+
:param str cluster_id: (required)
|
|
299
|
+
:param str node_name: (required)
|
|
300
|
+
:param datetime start: Date range.
|
|
301
|
+
:param datetime end:
|
|
302
|
+
:return: V1ListNodeMetricsResponse
|
|
303
|
+
If the method is called asynchronously,
|
|
304
|
+
returns the request thread.
|
|
305
|
+
"""
|
|
306
|
+
kwargs['_return_http_data_only'] = True
|
|
307
|
+
if kwargs.get('async_req'):
|
|
308
|
+
return self.k8_s_cluster_service_list_node_metrics_with_http_info(project_id, cluster_id, node_name, **kwargs) # noqa: E501
|
|
309
|
+
else:
|
|
310
|
+
(data) = self.k8_s_cluster_service_list_node_metrics_with_http_info(project_id, cluster_id, node_name, **kwargs) # noqa: E501
|
|
311
|
+
return data
|
|
312
|
+
|
|
313
|
+
def k8_s_cluster_service_list_node_metrics_with_http_info(self, project_id: 'str', cluster_id: 'str', node_name: 'str', **kwargs) -> 'V1ListNodeMetricsResponse': # noqa: E501
|
|
314
|
+
"""k8_s_cluster_service_list_node_metrics # noqa: E501
|
|
315
|
+
|
|
316
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
317
|
+
asynchronous HTTP request, please pass async_req=True
|
|
318
|
+
>>> thread = api.k8_s_cluster_service_list_node_metrics_with_http_info(project_id, cluster_id, node_name, async_req=True)
|
|
319
|
+
>>> result = thread.get()
|
|
320
|
+
|
|
321
|
+
:param async_req bool
|
|
322
|
+
:param str project_id: (required)
|
|
323
|
+
:param str cluster_id: (required)
|
|
324
|
+
:param str node_name: (required)
|
|
325
|
+
:param datetime start: Date range.
|
|
326
|
+
:param datetime end:
|
|
327
|
+
:return: V1ListNodeMetricsResponse
|
|
328
|
+
If the method is called asynchronously,
|
|
329
|
+
returns the request thread.
|
|
330
|
+
"""
|
|
331
|
+
|
|
332
|
+
all_params = ['project_id', 'cluster_id', 'node_name', 'start', 'end'] # noqa: E501
|
|
333
|
+
all_params.append('async_req')
|
|
334
|
+
all_params.append('_return_http_data_only')
|
|
335
|
+
all_params.append('_preload_content')
|
|
336
|
+
all_params.append('_request_timeout')
|
|
337
|
+
|
|
338
|
+
params = locals()
|
|
339
|
+
for key, val in six.iteritems(params['kwargs']):
|
|
340
|
+
if key not in all_params:
|
|
341
|
+
raise TypeError(
|
|
342
|
+
"Got an unexpected keyword argument '%s'"
|
|
343
|
+
" to method k8_s_cluster_service_list_node_metrics" % key
|
|
344
|
+
)
|
|
345
|
+
params[key] = val
|
|
346
|
+
del params['kwargs']
|
|
347
|
+
# verify the required parameter 'project_id' is set
|
|
348
|
+
if ('project_id' not in params or
|
|
349
|
+
params['project_id'] is None):
|
|
350
|
+
raise ValueError("Missing the required parameter `project_id` when calling `k8_s_cluster_service_list_node_metrics`") # noqa: E501
|
|
351
|
+
# verify the required parameter 'cluster_id' is set
|
|
352
|
+
if ('cluster_id' not in params or
|
|
353
|
+
params['cluster_id'] is None):
|
|
354
|
+
raise ValueError("Missing the required parameter `cluster_id` when calling `k8_s_cluster_service_list_node_metrics`") # noqa: E501
|
|
355
|
+
# verify the required parameter 'node_name' is set
|
|
356
|
+
if ('node_name' not in params or
|
|
357
|
+
params['node_name'] is None):
|
|
358
|
+
raise ValueError("Missing the required parameter `node_name` when calling `k8_s_cluster_service_list_node_metrics`") # noqa: E501
|
|
359
|
+
|
|
360
|
+
collection_formats = {}
|
|
361
|
+
|
|
362
|
+
path_params = {}
|
|
363
|
+
if 'project_id' in params:
|
|
364
|
+
path_params['projectId'] = params['project_id'] # noqa: E501
|
|
365
|
+
if 'cluster_id' in params:
|
|
366
|
+
path_params['clusterId'] = params['cluster_id'] # noqa: E501
|
|
367
|
+
if 'node_name' in params:
|
|
368
|
+
path_params['nodeName'] = params['node_name'] # noqa: E501
|
|
369
|
+
|
|
370
|
+
query_params = []
|
|
371
|
+
if 'start' in params:
|
|
372
|
+
query_params.append(('start', params['start'])) # noqa: E501
|
|
373
|
+
if 'end' in params:
|
|
374
|
+
query_params.append(('end', params['end'])) # noqa: E501
|
|
375
|
+
|
|
376
|
+
header_params = {}
|
|
377
|
+
|
|
378
|
+
form_params = []
|
|
379
|
+
local_var_files = {}
|
|
380
|
+
|
|
381
|
+
body_params = None
|
|
382
|
+
# HTTP header `Accept`
|
|
383
|
+
header_params['Accept'] = self.api_client.select_header_accept(
|
|
384
|
+
['application/json']) # noqa: E501
|
|
385
|
+
|
|
386
|
+
# Authentication setting
|
|
387
|
+
auth_settings = [] # noqa: E501
|
|
388
|
+
|
|
389
|
+
return self.api_client.call_api(
|
|
390
|
+
'/v1/projects/{projectId}/clusters/{clusterId}/metrics/nodes/{nodeName}', 'GET',
|
|
391
|
+
path_params,
|
|
392
|
+
query_params,
|
|
393
|
+
header_params,
|
|
394
|
+
body=body_params,
|
|
395
|
+
post_params=form_params,
|
|
396
|
+
files=local_var_files,
|
|
397
|
+
response_type='V1ListNodeMetricsResponse', # noqa: E501
|
|
398
|
+
auth_settings=auth_settings,
|
|
399
|
+
async_req=params.get('async_req'),
|
|
400
|
+
_return_http_data_only=params.get('_return_http_data_only'),
|
|
401
|
+
_preload_content=params.get('_preload_content', True),
|
|
402
|
+
_request_timeout=params.get('_request_timeout'),
|
|
403
|
+
collection_formats=collection_formats)
|
|
404
|
+
|
|
405
|
+
def k8_s_cluster_service_list_pod_metrics(self, project_id: 'str', cluster_id: 'str', pod_id: 'str', **kwargs) -> 'V1ListPodMetricsResponse': # noqa: E501
|
|
406
|
+
"""k8_s_cluster_service_list_pod_metrics # noqa: E501
|
|
407
|
+
|
|
408
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
409
|
+
asynchronous HTTP request, please pass async_req=True
|
|
410
|
+
>>> thread = api.k8_s_cluster_service_list_pod_metrics(project_id, cluster_id, pod_id, async_req=True)
|
|
411
|
+
>>> result = thread.get()
|
|
412
|
+
|
|
413
|
+
:param async_req bool
|
|
414
|
+
:param str project_id: (required)
|
|
415
|
+
:param str cluster_id: (required)
|
|
416
|
+
:param str pod_id: (required)
|
|
417
|
+
:param datetime start: Date range.
|
|
418
|
+
:param datetime end:
|
|
419
|
+
:return: V1ListPodMetricsResponse
|
|
420
|
+
If the method is called asynchronously,
|
|
421
|
+
returns the request thread.
|
|
422
|
+
"""
|
|
423
|
+
kwargs['_return_http_data_only'] = True
|
|
424
|
+
if kwargs.get('async_req'):
|
|
425
|
+
return self.k8_s_cluster_service_list_pod_metrics_with_http_info(project_id, cluster_id, pod_id, **kwargs) # noqa: E501
|
|
426
|
+
else:
|
|
427
|
+
(data) = self.k8_s_cluster_service_list_pod_metrics_with_http_info(project_id, cluster_id, pod_id, **kwargs) # noqa: E501
|
|
428
|
+
return data
|
|
429
|
+
|
|
430
|
+
def k8_s_cluster_service_list_pod_metrics_with_http_info(self, project_id: 'str', cluster_id: 'str', pod_id: 'str', **kwargs) -> 'V1ListPodMetricsResponse': # noqa: E501
|
|
431
|
+
"""k8_s_cluster_service_list_pod_metrics # noqa: E501
|
|
432
|
+
|
|
433
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
434
|
+
asynchronous HTTP request, please pass async_req=True
|
|
435
|
+
>>> thread = api.k8_s_cluster_service_list_pod_metrics_with_http_info(project_id, cluster_id, pod_id, async_req=True)
|
|
436
|
+
>>> result = thread.get()
|
|
437
|
+
|
|
438
|
+
:param async_req bool
|
|
439
|
+
:param str project_id: (required)
|
|
440
|
+
:param str cluster_id: (required)
|
|
441
|
+
:param str pod_id: (required)
|
|
442
|
+
:param datetime start: Date range.
|
|
443
|
+
:param datetime end:
|
|
444
|
+
:return: V1ListPodMetricsResponse
|
|
445
|
+
If the method is called asynchronously,
|
|
446
|
+
returns the request thread.
|
|
447
|
+
"""
|
|
448
|
+
|
|
449
|
+
all_params = ['project_id', 'cluster_id', 'pod_id', 'start', 'end'] # noqa: E501
|
|
450
|
+
all_params.append('async_req')
|
|
451
|
+
all_params.append('_return_http_data_only')
|
|
452
|
+
all_params.append('_preload_content')
|
|
453
|
+
all_params.append('_request_timeout')
|
|
454
|
+
|
|
455
|
+
params = locals()
|
|
456
|
+
for key, val in six.iteritems(params['kwargs']):
|
|
457
|
+
if key not in all_params:
|
|
458
|
+
raise TypeError(
|
|
459
|
+
"Got an unexpected keyword argument '%s'"
|
|
460
|
+
" to method k8_s_cluster_service_list_pod_metrics" % key
|
|
461
|
+
)
|
|
462
|
+
params[key] = val
|
|
463
|
+
del params['kwargs']
|
|
464
|
+
# verify the required parameter 'project_id' is set
|
|
465
|
+
if ('project_id' not in params or
|
|
466
|
+
params['project_id'] is None):
|
|
467
|
+
raise ValueError("Missing the required parameter `project_id` when calling `k8_s_cluster_service_list_pod_metrics`") # noqa: E501
|
|
468
|
+
# verify the required parameter 'cluster_id' is set
|
|
469
|
+
if ('cluster_id' not in params or
|
|
470
|
+
params['cluster_id'] is None):
|
|
471
|
+
raise ValueError("Missing the required parameter `cluster_id` when calling `k8_s_cluster_service_list_pod_metrics`") # noqa: E501
|
|
472
|
+
# verify the required parameter 'pod_id' is set
|
|
473
|
+
if ('pod_id' not in params or
|
|
474
|
+
params['pod_id'] is None):
|
|
475
|
+
raise ValueError("Missing the required parameter `pod_id` when calling `k8_s_cluster_service_list_pod_metrics`") # noqa: E501
|
|
476
|
+
|
|
477
|
+
collection_formats = {}
|
|
478
|
+
|
|
479
|
+
path_params = {}
|
|
480
|
+
if 'project_id' in params:
|
|
481
|
+
path_params['projectId'] = params['project_id'] # noqa: E501
|
|
482
|
+
if 'cluster_id' in params:
|
|
483
|
+
path_params['clusterId'] = params['cluster_id'] # noqa: E501
|
|
484
|
+
if 'pod_id' in params:
|
|
485
|
+
path_params['podId'] = params['pod_id'] # noqa: E501
|
|
486
|
+
|
|
487
|
+
query_params = []
|
|
488
|
+
if 'start' in params:
|
|
489
|
+
query_params.append(('start', params['start'])) # noqa: E501
|
|
490
|
+
if 'end' in params:
|
|
491
|
+
query_params.append(('end', params['end'])) # noqa: E501
|
|
492
|
+
|
|
493
|
+
header_params = {}
|
|
494
|
+
|
|
495
|
+
form_params = []
|
|
496
|
+
local_var_files = {}
|
|
497
|
+
|
|
498
|
+
body_params = None
|
|
499
|
+
# HTTP header `Accept`
|
|
500
|
+
header_params['Accept'] = self.api_client.select_header_accept(
|
|
501
|
+
['application/json']) # noqa: E501
|
|
502
|
+
|
|
503
|
+
# Authentication setting
|
|
504
|
+
auth_settings = [] # noqa: E501
|
|
505
|
+
|
|
506
|
+
return self.api_client.call_api(
|
|
507
|
+
'/v1/projects/{projectId}/clusters/{clusterId}/metrics/pods/{podId}', 'GET',
|
|
508
|
+
path_params,
|
|
509
|
+
query_params,
|
|
510
|
+
header_params,
|
|
511
|
+
body=body_params,
|
|
512
|
+
post_params=form_params,
|
|
513
|
+
files=local_var_files,
|
|
514
|
+
response_type='V1ListPodMetricsResponse', # noqa: E501
|
|
515
|
+
auth_settings=auth_settings,
|
|
516
|
+
async_req=params.get('async_req'),
|
|
517
|
+
_return_http_data_only=params.get('_return_http_data_only'),
|
|
518
|
+
_preload_content=params.get('_preload_content', True),
|
|
519
|
+
_request_timeout=params.get('_request_timeout'),
|
|
520
|
+
collection_formats=collection_formats)
|
|
521
|
+
|
|
522
|
+
def k8_s_cluster_service_report_k8_s_cluster_metrics(self, body: 'ClusterIdMetricsBody', cluster_id: 'str', **kwargs) -> 'V1ReportK8sClusterMetricsResponse': # noqa: E501
|
|
523
|
+
"""k8_s_cluster_service_report_k8_s_cluster_metrics # noqa: E501
|
|
524
|
+
|
|
525
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
526
|
+
asynchronous HTTP request, please pass async_req=True
|
|
527
|
+
>>> thread = api.k8_s_cluster_service_report_k8_s_cluster_metrics(body, cluster_id, async_req=True)
|
|
528
|
+
>>> result = thread.get()
|
|
529
|
+
|
|
530
|
+
:param async_req bool
|
|
531
|
+
:param ClusterIdMetricsBody body: (required)
|
|
532
|
+
:param str cluster_id: (required)
|
|
533
|
+
:return: V1ReportK8sClusterMetricsResponse
|
|
534
|
+
If the method is called asynchronously,
|
|
535
|
+
returns the request thread.
|
|
536
|
+
"""
|
|
537
|
+
kwargs['_return_http_data_only'] = True
|
|
538
|
+
if kwargs.get('async_req'):
|
|
539
|
+
return self.k8_s_cluster_service_report_k8_s_cluster_metrics_with_http_info(body, cluster_id, **kwargs) # noqa: E501
|
|
540
|
+
else:
|
|
541
|
+
(data) = self.k8_s_cluster_service_report_k8_s_cluster_metrics_with_http_info(body, cluster_id, **kwargs) # noqa: E501
|
|
542
|
+
return data
|
|
543
|
+
|
|
544
|
+
def k8_s_cluster_service_report_k8_s_cluster_metrics_with_http_info(self, body: 'ClusterIdMetricsBody', cluster_id: 'str', **kwargs) -> 'V1ReportK8sClusterMetricsResponse': # noqa: E501
|
|
545
|
+
"""k8_s_cluster_service_report_k8_s_cluster_metrics # noqa: E501
|
|
546
|
+
|
|
547
|
+
This method makes a synchronous HTTP request by default. To make an
|
|
548
|
+
asynchronous HTTP request, please pass async_req=True
|
|
549
|
+
>>> thread = api.k8_s_cluster_service_report_k8_s_cluster_metrics_with_http_info(body, cluster_id, async_req=True)
|
|
550
|
+
>>> result = thread.get()
|
|
551
|
+
|
|
552
|
+
:param async_req bool
|
|
553
|
+
:param ClusterIdMetricsBody body: (required)
|
|
554
|
+
:param str cluster_id: (required)
|
|
555
|
+
:return: V1ReportK8sClusterMetricsResponse
|
|
556
|
+
If the method is called asynchronously,
|
|
557
|
+
returns the request thread.
|
|
558
|
+
"""
|
|
559
|
+
|
|
560
|
+
all_params = ['body', 'cluster_id'] # noqa: E501
|
|
561
|
+
all_params.append('async_req')
|
|
562
|
+
all_params.append('_return_http_data_only')
|
|
563
|
+
all_params.append('_preload_content')
|
|
564
|
+
all_params.append('_request_timeout')
|
|
565
|
+
|
|
566
|
+
params = locals()
|
|
567
|
+
for key, val in six.iteritems(params['kwargs']):
|
|
568
|
+
if key not in all_params:
|
|
569
|
+
raise TypeError(
|
|
570
|
+
"Got an unexpected keyword argument '%s'"
|
|
571
|
+
" to method k8_s_cluster_service_report_k8_s_cluster_metrics" % key
|
|
572
|
+
)
|
|
573
|
+
params[key] = val
|
|
574
|
+
del params['kwargs']
|
|
575
|
+
# verify the required parameter 'body' is set
|
|
576
|
+
if ('body' not in params or
|
|
577
|
+
params['body'] is None):
|
|
578
|
+
raise ValueError("Missing the required parameter `body` when calling `k8_s_cluster_service_report_k8_s_cluster_metrics`") # noqa: E501
|
|
579
|
+
# verify the required parameter 'cluster_id' is set
|
|
580
|
+
if ('cluster_id' not in params or
|
|
581
|
+
params['cluster_id'] is None):
|
|
582
|
+
raise ValueError("Missing the required parameter `cluster_id` when calling `k8_s_cluster_service_report_k8_s_cluster_metrics`") # noqa: E501
|
|
583
|
+
|
|
584
|
+
collection_formats = {}
|
|
585
|
+
|
|
586
|
+
path_params = {}
|
|
587
|
+
if 'cluster_id' in params:
|
|
588
|
+
path_params['clusterId'] = params['cluster_id'] # noqa: E501
|
|
589
|
+
|
|
590
|
+
query_params = []
|
|
591
|
+
|
|
592
|
+
header_params = {}
|
|
593
|
+
|
|
594
|
+
form_params = []
|
|
595
|
+
local_var_files = {}
|
|
596
|
+
|
|
597
|
+
body_params = None
|
|
598
|
+
if 'body' in params:
|
|
599
|
+
body_params = params['body']
|
|
600
|
+
# HTTP header `Accept`
|
|
601
|
+
header_params['Accept'] = self.api_client.select_header_accept(
|
|
602
|
+
['application/json']) # noqa: E501
|
|
603
|
+
|
|
604
|
+
# HTTP header `Content-Type`
|
|
605
|
+
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
|
|
606
|
+
['application/json']) # noqa: E501
|
|
607
|
+
|
|
608
|
+
# Authentication setting
|
|
609
|
+
auth_settings = [] # noqa: E501
|
|
610
|
+
|
|
611
|
+
return self.api_client.call_api(
|
|
612
|
+
'/v1/k8s-clusters/{clusterId}/metrics', 'POST',
|
|
613
|
+
path_params,
|
|
614
|
+
query_params,
|
|
615
|
+
header_params,
|
|
616
|
+
body=body_params,
|
|
617
|
+
post_params=form_params,
|
|
618
|
+
files=local_var_files,
|
|
619
|
+
response_type='V1ReportK8sClusterMetricsResponse', # noqa: E501
|
|
620
|
+
auth_settings=auth_settings,
|
|
621
|
+
async_req=params.get('async_req'),
|
|
622
|
+
_return_http_data_only=params.get('_return_http_data_only'),
|
|
623
|
+
_preload_content=params.get('_preload_content', True),
|
|
624
|
+
_request_timeout=params.get('_request_timeout'),
|
|
625
|
+
collection_formats=collection_formats)
|
|
@@ -257,6 +257,7 @@ class StorageServiceApi(object):
|
|
|
257
257
|
:param str project_id: (required)
|
|
258
258
|
:param str cluster_id:
|
|
259
259
|
:param str filename:
|
|
260
|
+
:param str data_connection_id:
|
|
260
261
|
:return: V1DeleteProjectArtifactResponse
|
|
261
262
|
If the method is called asynchronously,
|
|
262
263
|
returns the request thread.
|
|
@@ -280,12 +281,13 @@ class StorageServiceApi(object):
|
|
|
280
281
|
:param str project_id: (required)
|
|
281
282
|
:param str cluster_id:
|
|
282
283
|
:param str filename:
|
|
284
|
+
:param str data_connection_id:
|
|
283
285
|
:return: V1DeleteProjectArtifactResponse
|
|
284
286
|
If the method is called asynchronously,
|
|
285
287
|
returns the request thread.
|
|
286
288
|
"""
|
|
287
289
|
|
|
288
|
-
all_params = ['project_id', 'cluster_id', 'filename'] # noqa: E501
|
|
290
|
+
all_params = ['project_id', 'cluster_id', 'filename', 'data_connection_id'] # noqa: E501
|
|
289
291
|
all_params.append('async_req')
|
|
290
292
|
all_params.append('_return_http_data_only')
|
|
291
293
|
all_params.append('_preload_content')
|
|
@@ -316,6 +318,8 @@ class StorageServiceApi(object):
|
|
|
316
318
|
query_params.append(('clusterId', params['cluster_id'])) # noqa: E501
|
|
317
319
|
if 'filename' in params:
|
|
318
320
|
query_params.append(('filename', params['filename'])) # noqa: E501
|
|
321
|
+
if 'data_connection_id' in params:
|
|
322
|
+
query_params.append(('dataConnectionId', params['data_connection_id'])) # noqa: E501
|
|
319
323
|
|
|
320
324
|
header_params = {}
|
|
321
325
|
|