4 cloudFPGA Resource Manager API
6 No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
8 OpenAPI spec version: 0.8
10 Generated by: https://github.com/swagger-api/swagger-codegen.git
13 from __future__
import absolute_import
20 from swagger_client.api_client
import ApiClient
24 """NOTE: This class is auto generated by the swagger code generator program.
26 Do not edit the class manually.
27 Ref: https://github.com/swagger-api/swagger-codegen
31 if api_client
is None:
36 """Remove a resource # noqa: E501
38 Please Note, after the deletion of a resource, the freed resource-id will be assigned again for new resources. # noqa: E501
39 This method makes a synchronous HTTP request by default. To make an
40 asynchronous HTTP request, please pass async_req=True
41 >>> thread = api.cf_manager_rest_api_delete_resource(username, password, resource_id, async_req=True)
42 >>> result = thread.get()
45 :param str username: OpenStack username (required)
46 :param str password: OpenStack password (required)
47 :param str resource_id: cloudFPGA resource unique identifier (required)
49 If the method is called asynchronously,
50 returns the request thread.
52 kwargs[
'_return_http_data_only'] =
True
53 if kwargs.get(
'async_req'):
60 """Remove a resource # noqa: E501
62 Please Note, after the deletion of a resource, the freed resource-id will be assigned again for new resources. # noqa: E501
63 This method makes a synchronous HTTP request by default. To make an
64 asynchronous HTTP request, please pass async_req=True
65 >>> thread = api.cf_manager_rest_api_delete_resource_with_http_info(username, password, resource_id, async_req=True)
66 >>> result = thread.get()
69 :param str username: OpenStack username (required)
70 :param str password: OpenStack password (required)
71 :param str resource_id: cloudFPGA resource unique identifier (required)
73 If the method is called asynchronously,
74 returns the request thread.
77 all_params = [
'username',
'password',
'resource_id']
78 all_params.append(
'async_req')
79 all_params.append(
'_return_http_data_only')
80 all_params.append(
'_preload_content')
81 all_params.append(
'_request_timeout')
84 for key, val
in six.iteritems(params[
'kwargs']):
85 if key
not in all_params:
87 "Got an unexpected keyword argument '%s'"
88 " to method cf_manager_rest_api_delete_resource" % key
93 if (
'username' not in params
or
94 params[
'username']
is None):
95 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_delete_resource`")
97 if (
'password' not in params
or
98 params[
'password']
is None):
99 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_delete_resource`")
101 if (
'resource_id' not in params
or
102 params[
'resource_id']
is None):
103 raise ValueError(
"Missing the required parameter `resource_id` when calling `cf_manager_rest_api_delete_resource`")
105 collection_formats = {}
108 if 'resource_id' in params:
109 path_params[
'resource_id'] = params[
'resource_id']
112 if 'username' in params:
113 query_params.append((
'username', params[
'username']))
114 if 'password' in params:
115 query_params.append((
'password', params[
'password']))
127 '/resources/{resource_id}',
'DELETE',
132 post_params=form_params,
133 files=local_var_files,
135 auth_settings=auth_settings,
136 async_req=params.get(
'async_req'),
137 _return_http_data_only=params.get(
'_return_http_data_only'),
138 _preload_content=params.get(
'_preload_content',
True),
139 _request_timeout=params.get(
'_request_timeout'),
140 collection_formats=collection_formats)
143 """Get all cloudFPGA resources in state `{status}` # noqa: E501
145 This method makes a synchronous HTTP request by default. To make an
146 asynchronous HTTP request, please pass async_req=True
147 >>> thread = api.cf_manager_rest_api_get_available_resources(username, password, status, async_req=True)
148 >>> result = thread.get()
150 :param async_req bool
151 :param str username: OpenStack username (required)
152 :param str password: OpenStack password (required)
153 :param str status: Status of the requested resources (required)
155 :return: list[Resource]
156 If the method is called asynchronously,
157 returns the request thread.
159 kwargs[
'_return_http_data_only'] =
True
160 if kwargs.get(
'async_req'):
167 """Get all cloudFPGA resources in state `{status}` # noqa: E501
169 This method makes a synchronous HTTP request by default. To make an
170 asynchronous HTTP request, please pass async_req=True
171 >>> thread = api.cf_manager_rest_api_get_available_resources_with_http_info(username, password, status, async_req=True)
172 >>> result = thread.get()
174 :param async_req bool
175 :param str username: OpenStack username (required)
176 :param str password: OpenStack password (required)
177 :param str status: Status of the requested resources (required)
179 :return: list[Resource]
180 If the method is called asynchronously,
181 returns the request thread.
184 all_params = [
'username',
'password',
'status',
'limit']
185 all_params.append(
'async_req')
186 all_params.append(
'_return_http_data_only')
187 all_params.append(
'_preload_content')
188 all_params.append(
'_request_timeout')
191 for key, val
in six.iteritems(params[
'kwargs']):
192 if key
not in all_params:
194 "Got an unexpected keyword argument '%s'"
195 " to method cf_manager_rest_api_get_available_resources" % key
200 if (
'username' not in params
or
201 params[
'username']
is None):
202 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_available_resources`")
204 if (
'password' not in params
or
205 params[
'password']
is None):
206 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_available_resources`")
208 if (
'status' not in params
or
209 params[
'status']
is None):
210 raise ValueError(
"Missing the required parameter `status` when calling `cf_manager_rest_api_get_available_resources`")
212 collection_formats = {}
215 if 'status' in params:
216 path_params[
'status'] = params[
'status']
219 if 'username' in params:
220 query_params.append((
'username', params[
'username']))
221 if 'password' in params:
222 query_params.append((
'password', params[
'password']))
223 if 'limit' in params:
224 query_params.append((
'limit', params[
'limit']))
233 header_params[
'Accept'] = self.
api_clientapi_client.select_header_accept(
234 [
'application/json'])
240 '/resources/status/{status}',
'GET',
245 post_params=form_params,
246 files=local_var_files,
247 response_type=
'list[Resource]',
248 auth_settings=auth_settings,
249 async_req=params.get(
'async_req'),
250 _return_http_data_only=params.get(
'_return_http_data_only'),
251 _preload_content=params.get(
'_preload_content',
True),
252 _request_timeout=params.get(
'_request_timeout'),
253 collection_formats=collection_formats)
256 """Get all cloudFPGA resources # noqa: E501
258 This method makes a synchronous HTTP request by default. To make an
259 asynchronous HTTP request, please pass async_req=True
260 >>> thread = api.cf_manager_rest_api_get_resources(username, password, async_req=True)
261 >>> result = thread.get()
263 :param async_req bool
264 :param str username: OpenStack username (required)
265 :param str password: OpenStack password (required)
267 :return: list[Resource]
268 If the method is called asynchronously,
269 returns the request thread.
271 kwargs[
'_return_http_data_only'] =
True
272 if kwargs.get(
'async_req'):
279 """Get all cloudFPGA resources # noqa: E501
281 This method makes a synchronous HTTP request by default. To make an
282 asynchronous HTTP request, please pass async_req=True
283 >>> thread = api.cf_manager_rest_api_get_resources_with_http_info(username, password, async_req=True)
284 >>> result = thread.get()
286 :param async_req bool
287 :param str username: OpenStack username (required)
288 :param str password: OpenStack password (required)
290 :return: list[Resource]
291 If the method is called asynchronously,
292 returns the request thread.
295 all_params = [
'username',
'password',
'limit']
296 all_params.append(
'async_req')
297 all_params.append(
'_return_http_data_only')
298 all_params.append(
'_preload_content')
299 all_params.append(
'_request_timeout')
302 for key, val
in six.iteritems(params[
'kwargs']):
303 if key
not in all_params:
305 "Got an unexpected keyword argument '%s'"
306 " to method cf_manager_rest_api_get_resources" % key
311 if (
'username' not in params
or
312 params[
'username']
is None):
313 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_resources`")
315 if (
'password' not in params
or
316 params[
'password']
is None):
317 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_resources`")
319 collection_formats = {}
324 if 'username' in params:
325 query_params.append((
'username', params[
'username']))
326 if 'password' in params:
327 query_params.append((
'password', params[
'password']))
328 if 'limit' in params:
329 query_params.append((
'limit', params[
'limit']))
338 header_params[
'Accept'] = self.
api_clientapi_client.select_header_accept(
339 [
'application/json'])
350 post_params=form_params,
351 files=local_var_files,
352 response_type=
'list[Resource]',
353 auth_settings=auth_settings,
354 async_req=params.get(
'async_req'),
355 _return_http_data_only=params.get(
'_return_http_data_only'),
356 _preload_content=params.get(
'_preload_content',
True),
357 _request_timeout=params.get(
'_request_timeout'),
358 collection_formats=collection_formats)
361 """Get status of **all resources** from a specific sled # noqa: E501
363 This method makes a synchronous HTTP request by default. To make an
364 asynchronous HTTP request, please pass async_req=True
365 >>> thread = api.cf_manager_rest_api_get_resources_of_sled_status(username, password, sled_ip, async_req=True)
366 >>> result = thread.get()
368 :param async_req bool
369 :param str username: OpenStack username (required)
370 :param str password: OpenStack password (required)
371 :param str sled_ip: The ip address of a SM (required)
373 If the method is called asynchronously,
374 returns the request thread.
376 kwargs[
'_return_http_data_only'] =
True
377 if kwargs.get(
'async_req'):
384 """Get status of **all resources** from a specific sled # noqa: E501
386 This method makes a synchronous HTTP request by default. To make an
387 asynchronous HTTP request, please pass async_req=True
388 >>> thread = api.cf_manager_rest_api_get_resources_of_sled_status_with_http_info(username, password, sled_ip, async_req=True)
389 >>> result = thread.get()
391 :param async_req bool
392 :param str username: OpenStack username (required)
393 :param str password: OpenStack password (required)
394 :param str sled_ip: The ip address of a SM (required)
396 If the method is called asynchronously,
397 returns the request thread.
400 all_params = [
'username',
'password',
'sled_ip']
401 all_params.append(
'async_req')
402 all_params.append(
'_return_http_data_only')
403 all_params.append(
'_preload_content')
404 all_params.append(
'_request_timeout')
407 for key, val
in six.iteritems(params[
'kwargs']):
408 if key
not in all_params:
410 "Got an unexpected keyword argument '%s'"
411 " to method cf_manager_rest_api_get_resources_of_sled_status" % key
416 if (
'username' not in params
or
417 params[
'username']
is None):
418 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_resources_of_sled_status`")
420 if (
'password' not in params
or
421 params[
'password']
is None):
422 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_resources_of_sled_status`")
424 if (
'sled_ip' not in params
or
425 params[
'sled_ip']
is None):
426 raise ValueError(
"Missing the required parameter `sled_ip` when calling `cf_manager_rest_api_get_resources_of_sled_status`")
428 collection_formats = {}
431 if 'sled_ip' in params:
432 path_params[
'sled_ip'] = params[
'sled_ip']
435 if 'username' in params:
436 query_params.append((
'username', params[
'username']))
437 if 'password' in params:
438 query_params.append((
'password', params[
'password']))
450 '/resources/sled/{sled_ip}/status/',
'GET',
455 post_params=form_params,
456 files=local_var_files,
458 auth_settings=auth_settings,
459 async_req=params.get(
'async_req'),
460 _return_http_data_only=params.get(
'_return_http_data_only'),
461 _preload_content=params.get(
'_preload_content',
True),
462 _request_timeout=params.get(
'_request_timeout'),
463 collection_formats=collection_formats)
466 """Get status of **all resources** from a specific sled in a specific `{status}` # noqa: E501
468 This method makes a synchronous HTTP request by default. To make an
469 asynchronous HTTP request, please pass async_req=True
470 >>> thread = api.cf_manager_rest_api_get_resources_of_sled_status_in_state(username, password, sled_ip, status, async_req=True)
471 >>> result = thread.get()
473 :param async_req bool
474 :param str username: OpenStack username (required)
475 :param str password: OpenStack password (required)
476 :param str sled_ip: The ip address of a SM (required)
477 :param str status: Status of the requested resources (required)
479 If the method is called asynchronously,
480 returns the request thread.
482 kwargs[
'_return_http_data_only'] =
True
483 if kwargs.get(
'async_req'):
490 """Get status of **all resources** from a specific sled in a specific `{status}` # noqa: E501
492 This method makes a synchronous HTTP request by default. To make an
493 asynchronous HTTP request, please pass async_req=True
494 >>> thread = api.cf_manager_rest_api_get_resources_of_sled_status_in_state_with_http_info(username, password, sled_ip, status, async_req=True)
495 >>> result = thread.get()
497 :param async_req bool
498 :param str username: OpenStack username (required)
499 :param str password: OpenStack password (required)
500 :param str sled_ip: The ip address of a SM (required)
501 :param str status: Status of the requested resources (required)
503 If the method is called asynchronously,
504 returns the request thread.
507 all_params = [
'username',
'password',
'sled_ip',
'status']
508 all_params.append(
'async_req')
509 all_params.append(
'_return_http_data_only')
510 all_params.append(
'_preload_content')
511 all_params.append(
'_request_timeout')
514 for key, val
in six.iteritems(params[
'kwargs']):
515 if key
not in all_params:
517 "Got an unexpected keyword argument '%s'"
518 " to method cf_manager_rest_api_get_resources_of_sled_status_in_state" % key
523 if (
'username' not in params
or
524 params[
'username']
is None):
525 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_resources_of_sled_status_in_state`")
527 if (
'password' not in params
or
528 params[
'password']
is None):
529 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_resources_of_sled_status_in_state`")
531 if (
'sled_ip' not in params
or
532 params[
'sled_ip']
is None):
533 raise ValueError(
"Missing the required parameter `sled_ip` when calling `cf_manager_rest_api_get_resources_of_sled_status_in_state`")
535 if (
'status' not in params
or
536 params[
'status']
is None):
537 raise ValueError(
"Missing the required parameter `status` when calling `cf_manager_rest_api_get_resources_of_sled_status_in_state`")
539 collection_formats = {}
542 if 'sled_ip' in params:
543 path_params[
'sled_ip'] = params[
'sled_ip']
544 if 'status' in params:
545 path_params[
'status'] = params[
'status']
548 if 'username' in params:
549 query_params.append((
'username', params[
'username']))
550 if 'password' in params:
551 query_params.append((
'password', params[
'password']))
563 '/resources/sled/{sled_ip}/{status}/',
'GET',
568 post_params=form_params,
569 files=local_var_files,
571 auth_settings=auth_settings,
572 async_req=params.get(
'async_req'),
573 _return_http_data_only=params.get(
'_return_http_data_only'),
574 _preload_content=params.get(
'_preload_content',
True),
575 _request_timeout=params.get(
'_request_timeout'),
576 collection_formats=collection_formats)
579 """Get details of one resource # noqa: E501
581 This method makes a synchronous HTTP request by default. To make an
582 asynchronous HTTP request, please pass async_req=True
583 >>> thread = api.cf_manager_rest_api_get_single_resource(username, password, resource_id, async_req=True)
584 >>> result = thread.get()
586 :param async_req bool
587 :param str username: OpenStack username (required)
588 :param str password: OpenStack password (required)
589 :param str resource_id: cloudFPGA resource unique identifier (required)
591 If the method is called asynchronously,
592 returns the request thread.
594 kwargs[
'_return_http_data_only'] =
True
595 if kwargs.get(
'async_req'):
602 """Get details of one resource # noqa: E501
604 This method makes a synchronous HTTP request by default. To make an
605 asynchronous HTTP request, please pass async_req=True
606 >>> thread = api.cf_manager_rest_api_get_single_resource_with_http_info(username, password, resource_id, async_req=True)
607 >>> result = thread.get()
609 :param async_req bool
610 :param str username: OpenStack username (required)
611 :param str password: OpenStack password (required)
612 :param str resource_id: cloudFPGA resource unique identifier (required)
614 If the method is called asynchronously,
615 returns the request thread.
618 all_params = [
'username',
'password',
'resource_id']
619 all_params.append(
'async_req')
620 all_params.append(
'_return_http_data_only')
621 all_params.append(
'_preload_content')
622 all_params.append(
'_request_timeout')
625 for key, val
in six.iteritems(params[
'kwargs']):
626 if key
not in all_params:
628 "Got an unexpected keyword argument '%s'"
629 " to method cf_manager_rest_api_get_single_resource" % key
634 if (
'username' not in params
or
635 params[
'username']
is None):
636 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_single_resource`")
638 if (
'password' not in params
or
639 params[
'password']
is None):
640 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_single_resource`")
642 if (
'resource_id' not in params
or
643 params[
'resource_id']
is None):
644 raise ValueError(
"Missing the required parameter `resource_id` when calling `cf_manager_rest_api_get_single_resource`")
646 collection_formats = {}
649 if 'resource_id' in params:
650 path_params[
'resource_id'] = params[
'resource_id']
653 if 'username' in params:
654 query_params.append((
'username', params[
'username']))
655 if 'password' in params:
656 query_params.append((
'password', params[
'password']))
665 header_params[
'Accept'] = self.
api_clientapi_client.select_header_accept(
666 [
'application/json'])
672 '/resources/{resource_id}',
'GET',
677 post_params=form_params,
678 files=local_var_files,
679 response_type=
'Resource',
680 auth_settings=auth_settings,
681 async_req=params.get(
'async_req'),
682 _return_http_data_only=params.get(
'_return_http_data_only'),
683 _preload_content=params.get(
'_preload_content',
True),
684 _request_timeout=params.get(
'_request_timeout'),
685 collection_formats=collection_formats)
688 """Get status of one resource # noqa: E501
690 This method makes a synchronous HTTP request by default. To make an
691 asynchronous HTTP request, please pass async_req=True
692 >>> thread = api.cf_manager_rest_api_get_single_resource_status(username, password, resource_id, async_req=True)
693 >>> result = thread.get()
695 :param async_req bool
696 :param str username: OpenStack username (required)
697 :param str password: OpenStack password (required)
698 :param str resource_id: cloudFPGA resource unique identifier (required)
699 :return: InlineResponse2006
700 If the method is called asynchronously,
701 returns the request thread.
703 kwargs[
'_return_http_data_only'] =
True
704 if kwargs.get(
'async_req'):
711 """Get status of one resource # noqa: E501
713 This method makes a synchronous HTTP request by default. To make an
714 asynchronous HTTP request, please pass async_req=True
715 >>> thread = api.cf_manager_rest_api_get_single_resource_status_with_http_info(username, password, resource_id, async_req=True)
716 >>> result = thread.get()
718 :param async_req bool
719 :param str username: OpenStack username (required)
720 :param str password: OpenStack password (required)
721 :param str resource_id: cloudFPGA resource unique identifier (required)
722 :return: InlineResponse2006
723 If the method is called asynchronously,
724 returns the request thread.
727 all_params = [
'username',
'password',
'resource_id']
728 all_params.append(
'async_req')
729 all_params.append(
'_return_http_data_only')
730 all_params.append(
'_preload_content')
731 all_params.append(
'_request_timeout')
734 for key, val
in six.iteritems(params[
'kwargs']):
735 if key
not in all_params:
737 "Got an unexpected keyword argument '%s'"
738 " to method cf_manager_rest_api_get_single_resource_status" % key
743 if (
'username' not in params
or
744 params[
'username']
is None):
745 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_get_single_resource_status`")
747 if (
'password' not in params
or
748 params[
'password']
is None):
749 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_get_single_resource_status`")
751 if (
'resource_id' not in params
or
752 params[
'resource_id']
is None):
753 raise ValueError(
"Missing the required parameter `resource_id` when calling `cf_manager_rest_api_get_single_resource_status`")
755 collection_formats = {}
758 if 'resource_id' in params:
759 path_params[
'resource_id'] = params[
'resource_id']
762 if 'username' in params:
763 query_params.append((
'username', params[
'username']))
764 if 'password' in params:
765 query_params.append((
'password', params[
'password']))
774 header_params[
'Accept'] = self.
api_clientapi_client.select_header_accept(
775 [
'application/json'])
781 '/resources/{resource_id}/status/',
'GET',
786 post_params=form_params,
787 files=local_var_files,
788 response_type=
'InlineResponse2006',
789 auth_settings=auth_settings,
790 async_req=params.get(
'async_req'),
791 _return_http_data_only=params.get(
'_return_http_data_only'),
792 _preload_content=params.get(
'_preload_content',
True),
793 _request_timeout=params.get(
'_request_timeout'),
794 collection_formats=collection_formats)
797 """Create a cloudFPGA resource # noqa: E501
799 This method makes a synchronous HTTP request by default. To make an
800 asynchronous HTTP request, please pass async_req=True
801 >>> thread = api.cf_manager_rest_api_post_resources(username, password, async_req=True)
802 >>> result = thread.get()
804 :param async_req bool
805 :param str username: OpenStack username (required)
806 :param str password: OpenStack password (required)
807 :param Resource body:
809 If the method is called asynchronously,
810 returns the request thread.
812 kwargs[
'_return_http_data_only'] =
True
813 if kwargs.get(
'async_req'):
820 """Create a cloudFPGA resource # noqa: E501
822 This method makes a synchronous HTTP request by default. To make an
823 asynchronous HTTP request, please pass async_req=True
824 >>> thread = api.cf_manager_rest_api_post_resources_with_http_info(username, password, async_req=True)
825 >>> result = thread.get()
827 :param async_req bool
828 :param str username: OpenStack username (required)
829 :param str password: OpenStack password (required)
830 :param Resource body:
832 If the method is called asynchronously,
833 returns the request thread.
836 all_params = [
'username',
'password',
'body']
837 all_params.append(
'async_req')
838 all_params.append(
'_return_http_data_only')
839 all_params.append(
'_preload_content')
840 all_params.append(
'_request_timeout')
843 for key, val
in six.iteritems(params[
'kwargs']):
844 if key
not in all_params:
846 "Got an unexpected keyword argument '%s'"
847 " to method cf_manager_rest_api_post_resources" % key
852 if (
'username' not in params
or
853 params[
'username']
is None):
854 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_post_resources`")
856 if (
'password' not in params
or
857 params[
'password']
is None):
858 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_post_resources`")
860 collection_formats = {}
865 if 'username' in params:
866 query_params.append((
'username', params[
'username']))
867 if 'password' in params:
868 query_params.append((
'password', params[
'password']))
877 body_params = params[
'body']
879 header_params[
'Content-Type'] = self.
api_clientapi_client.select_header_content_type(
880 [
'application/json'])
886 '/resources',
'POST',
891 post_params=form_params,
892 files=local_var_files,
894 auth_settings=auth_settings,
895 async_req=params.get(
'async_req'),
896 _return_http_data_only=params.get(
'_return_http_data_only'),
897 _preload_content=params.get(
'_preload_content',
True),
898 _request_timeout=params.get(
'_request_timeout'),
899 collection_formats=collection_formats)
902 """Update a resource # noqa: E501
904 Only the properties to update must be part of the `resource_data` field. All not mentioned properties will stay the same. It is not possible to change the `state` with this API call. # noqa: E501
905 This method makes a synchronous HTTP request by default. To make an
906 asynchronous HTTP request, please pass async_req=True
907 >>> thread = api.cf_manager_rest_api_put_resource(username, password, resource_id, async_req=True)
908 >>> result = thread.get()
910 :param async_req bool
911 :param str username: OpenStack username (required)
912 :param str password: OpenStack password (required)
913 :param str resource_id: cloudFPGA resource unique identifier (required)
914 :param Resource body:
916 If the method is called asynchronously,
917 returns the request thread.
919 kwargs[
'_return_http_data_only'] =
True
920 if kwargs.get(
'async_req'):
927 """Update a resource # noqa: E501
929 Only the properties to update must be part of the `resource_data` field. All not mentioned properties will stay the same. It is not possible to change the `state` with this API call. # noqa: E501
930 This method makes a synchronous HTTP request by default. To make an
931 asynchronous HTTP request, please pass async_req=True
932 >>> thread = api.cf_manager_rest_api_put_resource_with_http_info(username, password, resource_id, async_req=True)
933 >>> result = thread.get()
935 :param async_req bool
936 :param str username: OpenStack username (required)
937 :param str password: OpenStack password (required)
938 :param str resource_id: cloudFPGA resource unique identifier (required)
939 :param Resource body:
941 If the method is called asynchronously,
942 returns the request thread.
945 all_params = [
'username',
'password',
'resource_id',
'body']
946 all_params.append(
'async_req')
947 all_params.append(
'_return_http_data_only')
948 all_params.append(
'_preload_content')
949 all_params.append(
'_request_timeout')
952 for key, val
in six.iteritems(params[
'kwargs']):
953 if key
not in all_params:
955 "Got an unexpected keyword argument '%s'"
956 " to method cf_manager_rest_api_put_resource" % key
961 if (
'username' not in params
or
962 params[
'username']
is None):
963 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_put_resource`")
965 if (
'password' not in params
or
966 params[
'password']
is None):
967 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_put_resource`")
969 if (
'resource_id' not in params
or
970 params[
'resource_id']
is None):
971 raise ValueError(
"Missing the required parameter `resource_id` when calling `cf_manager_rest_api_put_resource`")
973 collection_formats = {}
976 if 'resource_id' in params:
977 path_params[
'resource_id'] = params[
'resource_id']
980 if 'username' in params:
981 query_params.append((
'username', params[
'username']))
982 if 'password' in params:
983 query_params.append((
'password', params[
'password']))
992 body_params = params[
'body']
994 header_params[
'Content-Type'] = self.
api_clientapi_client.select_header_content_type(
995 [
'application/json'])
1001 '/resources/{resource_id}',
'PUT',
1006 post_params=form_params,
1007 files=local_var_files,
1009 auth_settings=auth_settings,
1010 async_req=params.get(
'async_req'),
1011 _return_http_data_only=params.get(
'_return_http_data_only'),
1012 _preload_content=params.get(
'_preload_content',
True),
1013 _request_timeout=params.get(
'_request_timeout'),
1014 collection_formats=collection_formats)
1017 """Update status of a resource # noqa: E501
1019 This method makes a synchronous HTTP request by default. To make an
1020 asynchronous HTTP request, please pass async_req=True
1021 >>> thread = api.cf_manager_rest_api_put_resource_status(username, password, resource_id, new_status, async_req=True)
1022 >>> result = thread.get()
1024 :param async_req bool
1025 :param str username: OpenStack username (required)
1026 :param str password: OpenStack password (required)
1027 :param str resource_id: cloudFPGA resource unique identifier (required)
1028 :param str new_status: New status of the resource (required)
1030 If the method is called asynchronously,
1031 returns the request thread.
1033 kwargs[
'_return_http_data_only'] =
True
1034 if kwargs.get(
'async_req'):
1041 """Update status of a resource # noqa: E501
1043 This method makes a synchronous HTTP request by default. To make an
1044 asynchronous HTTP request, please pass async_req=True
1045 >>> thread = api.cf_manager_rest_api_put_resource_status_with_http_info(username, password, resource_id, new_status, async_req=True)
1046 >>> result = thread.get()
1048 :param async_req bool
1049 :param str username: OpenStack username (required)
1050 :param str password: OpenStack password (required)
1051 :param str resource_id: cloudFPGA resource unique identifier (required)
1052 :param str new_status: New status of the resource (required)
1054 If the method is called asynchronously,
1055 returns the request thread.
1058 all_params = [
'username',
'password',
'resource_id',
'new_status']
1059 all_params.append(
'async_req')
1060 all_params.append(
'_return_http_data_only')
1061 all_params.append(
'_preload_content')
1062 all_params.append(
'_request_timeout')
1065 for key, val
in six.iteritems(params[
'kwargs']):
1066 if key
not in all_params:
1068 "Got an unexpected keyword argument '%s'"
1069 " to method cf_manager_rest_api_put_resource_status" % key
1072 del params[
'kwargs']
1074 if (
'username' not in params
or
1075 params[
'username']
is None):
1076 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_put_resource_status`")
1078 if (
'password' not in params
or
1079 params[
'password']
is None):
1080 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_put_resource_status`")
1082 if (
'resource_id' not in params
or
1083 params[
'resource_id']
is None):
1084 raise ValueError(
"Missing the required parameter `resource_id` when calling `cf_manager_rest_api_put_resource_status`")
1086 if (
'new_status' not in params
or
1087 params[
'new_status']
is None):
1088 raise ValueError(
"Missing the required parameter `new_status` when calling `cf_manager_rest_api_put_resource_status`")
1090 collection_formats = {}
1093 if 'resource_id' in params:
1094 path_params[
'resource_id'] = params[
'resource_id']
1097 if 'username' in params:
1098 query_params.append((
'username', params[
'username']))
1099 if 'password' in params:
1100 query_params.append((
'password', params[
'password']))
1101 if 'new_status' in params:
1102 query_params.append((
'new_status', params[
'new_status']))
1107 local_var_files = {}
1114 '/resources/{resource_id}/status/',
'PUT',
1119 post_params=form_params,
1120 files=local_var_files,
1122 auth_settings=auth_settings,
1123 async_req=params.get(
'async_req'),
1124 _return_http_data_only=params.get(
'_return_http_data_only'),
1125 _preload_content=params.get(
'_preload_content',
True),
1126 _request_timeout=params.get(
'_request_timeout'),
1127 collection_formats=collection_formats)
1130 """Update status of **all resources** from a specific sled # noqa: E501
1132 This method makes a synchronous HTTP request by default. To make an
1133 asynchronous HTTP request, please pass async_req=True
1134 >>> thread = api.cf_manager_rest_api_put_resources_of_sled_status(username, password, sled_ip, new_status, async_req=True)
1135 >>> result = thread.get()
1137 :param async_req bool
1138 :param str username: OpenStack username (required)
1139 :param str password: OpenStack password (required)
1140 :param str sled_ip: The ip address of a SM (required)
1141 :param str new_status: New status of the resource (required)
1143 If the method is called asynchronously,
1144 returns the request thread.
1146 kwargs[
'_return_http_data_only'] =
True
1147 if kwargs.get(
'async_req'):
1154 """Update status of **all resources** from a specific sled # noqa: E501
1156 This method makes a synchronous HTTP request by default. To make an
1157 asynchronous HTTP request, please pass async_req=True
1158 >>> thread = api.cf_manager_rest_api_put_resources_of_sled_status_with_http_info(username, password, sled_ip, new_status, async_req=True)
1159 >>> result = thread.get()
1161 :param async_req bool
1162 :param str username: OpenStack username (required)
1163 :param str password: OpenStack password (required)
1164 :param str sled_ip: The ip address of a SM (required)
1165 :param str new_status: New status of the resource (required)
1167 If the method is called asynchronously,
1168 returns the request thread.
1171 all_params = [
'username',
'password',
'sled_ip',
'new_status']
1172 all_params.append(
'async_req')
1173 all_params.append(
'_return_http_data_only')
1174 all_params.append(
'_preload_content')
1175 all_params.append(
'_request_timeout')
1178 for key, val
in six.iteritems(params[
'kwargs']):
1179 if key
not in all_params:
1181 "Got an unexpected keyword argument '%s'"
1182 " to method cf_manager_rest_api_put_resources_of_sled_status" % key
1185 del params[
'kwargs']
1187 if (
'username' not in params
or
1188 params[
'username']
is None):
1189 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_put_resources_of_sled_status`")
1191 if (
'password' not in params
or
1192 params[
'password']
is None):
1193 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_put_resources_of_sled_status`")
1195 if (
'sled_ip' not in params
or
1196 params[
'sled_ip']
is None):
1197 raise ValueError(
"Missing the required parameter `sled_ip` when calling `cf_manager_rest_api_put_resources_of_sled_status`")
1199 if (
'new_status' not in params
or
1200 params[
'new_status']
is None):
1201 raise ValueError(
"Missing the required parameter `new_status` when calling `cf_manager_rest_api_put_resources_of_sled_status`")
1203 collection_formats = {}
1206 if 'sled_ip' in params:
1207 path_params[
'sled_ip'] = params[
'sled_ip']
1210 if 'username' in params:
1211 query_params.append((
'username', params[
'username']))
1212 if 'password' in params:
1213 query_params.append((
'password', params[
'password']))
1214 if 'new_status' in params:
1215 query_params.append((
'new_status', params[
'new_status']))
1220 local_var_files = {}
1227 '/resources/sled/{sled_ip}/status/',
'PUT',
1232 post_params=form_params,
1233 files=local_var_files,
1235 auth_settings=auth_settings,
1236 async_req=params.get(
'async_req'),
1237 _return_http_data_only=params.get(
'_return_http_data_only'),
1238 _preload_content=params.get(
'_preload_content',
True),
1239 _request_timeout=params.get(
'_request_timeout'),
1240 collection_formats=collection_formats)
1243 """Update status of **all resources** from a specific sled in a specific `{status}` # noqa: E501
1245 For example, if this method is called with `PUT /resources/sled/1.2.3.4/AVAILABLE`, then only all `AVAILABLE` resources of Sled `1.2.3.4` are put to to the `new_status`. # noqa: E501
1246 This method makes a synchronous HTTP request by default. To make an
1247 asynchronous HTTP request, please pass async_req=True
1248 >>> thread = api.cf_manager_rest_api_put_resources_of_sled_status_in_state(username, password, sled_ip, status, new_status, async_req=True)
1249 >>> result = thread.get()
1251 :param async_req bool
1252 :param str username: OpenStack username (required)
1253 :param str password: OpenStack password (required)
1254 :param str sled_ip: The ip address of a SM (required)
1255 :param str status: Status of the resources that should be updated (required)
1256 :param str new_status: New status of the resources (required)
1258 If the method is called asynchronously,
1259 returns the request thread.
1261 kwargs[
'_return_http_data_only'] =
True
1262 if kwargs.get(
'async_req'):
1269 """Update status of **all resources** from a specific sled in a specific `{status}` # noqa: E501
1271 For example, if this method is called with `PUT /resources/sled/1.2.3.4/AVAILABLE`, then only all `AVAILABLE` resources of Sled `1.2.3.4` are put to to the `new_status`. # noqa: E501
1272 This method makes a synchronous HTTP request by default. To make an
1273 asynchronous HTTP request, please pass async_req=True
1274 >>> thread = api.cf_manager_rest_api_put_resources_of_sled_status_in_state_with_http_info(username, password, sled_ip, status, new_status, async_req=True)
1275 >>> result = thread.get()
1277 :param async_req bool
1278 :param str username: OpenStack username (required)
1279 :param str password: OpenStack password (required)
1280 :param str sled_ip: The ip address of a SM (required)
1281 :param str status: Status of the resources that should be updated (required)
1282 :param str new_status: New status of the resources (required)
1284 If the method is called asynchronously,
1285 returns the request thread.
1288 all_params = [
'username',
'password',
'sled_ip',
'status',
'new_status']
1289 all_params.append(
'async_req')
1290 all_params.append(
'_return_http_data_only')
1291 all_params.append(
'_preload_content')
1292 all_params.append(
'_request_timeout')
1295 for key, val
in six.iteritems(params[
'kwargs']):
1296 if key
not in all_params:
1298 "Got an unexpected keyword argument '%s'"
1299 " to method cf_manager_rest_api_put_resources_of_sled_status_in_state" % key
1302 del params[
'kwargs']
1304 if (
'username' not in params
or
1305 params[
'username']
is None):
1306 raise ValueError(
"Missing the required parameter `username` when calling `cf_manager_rest_api_put_resources_of_sled_status_in_state`")
1308 if (
'password' not in params
or
1309 params[
'password']
is None):
1310 raise ValueError(
"Missing the required parameter `password` when calling `cf_manager_rest_api_put_resources_of_sled_status_in_state`")
1312 if (
'sled_ip' not in params
or
1313 params[
'sled_ip']
is None):
1314 raise ValueError(
"Missing the required parameter `sled_ip` when calling `cf_manager_rest_api_put_resources_of_sled_status_in_state`")
1316 if (
'status' not in params
or
1317 params[
'status']
is None):
1318 raise ValueError(
"Missing the required parameter `status` when calling `cf_manager_rest_api_put_resources_of_sled_status_in_state`")
1320 if (
'new_status' not in params
or
1321 params[
'new_status']
is None):
1322 raise ValueError(
"Missing the required parameter `new_status` when calling `cf_manager_rest_api_put_resources_of_sled_status_in_state`")
1324 collection_formats = {}
1327 if 'sled_ip' in params:
1328 path_params[
'sled_ip'] = params[
'sled_ip']
1329 if 'status' in params:
1330 path_params[
'status'] = params[
'status']
1333 if 'username' in params:
1334 query_params.append((
'username', params[
'username']))
1335 if 'password' in params:
1336 query_params.append((
'password', params[
'password']))
1337 if 'new_status' in params:
1338 query_params.append((
'new_status', params[
'new_status']))
1343 local_var_files = {}
1350 '/resources/sled/{sled_ip}/{status}/',
'PUT',
1355 post_params=form_params,
1356 files=local_var_files,
1358 auth_settings=auth_settings,
1359 async_req=params.get(
'async_req'),
1360 _return_http_data_only=params.get(
'_return_http_data_only'),
1361 _preload_content=params.get(
'_preload_content',
True),
1362 _request_timeout=params.get(
'_request_timeout'),
1363 collection_formats=collection_formats)
def cf_manager_rest_api_get_single_resource_status_with_http_info(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_get_resources_of_sled_status(self, username, password, sled_ip, **kwargs)
def cf_manager_rest_api_get_available_resources_with_http_info(self, username, password, status, **kwargs)
def cf_manager_rest_api_get_resources_of_sled_status_in_state(self, username, password, sled_ip, status, **kwargs)
def cf_manager_rest_api_get_resources_of_sled_status_in_state_with_http_info(self, username, password, sled_ip, status, **kwargs)
def cf_manager_rest_api_get_resources(self, username, password, **kwargs)
def cf_manager_rest_api_put_resource_with_http_info(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_delete_resource_with_http_info(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_put_resources_of_sled_status_in_state(self, username, password, sled_ip, status, new_status, **kwargs)
def cf_manager_rest_api_put_resource(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_delete_resource(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_get_available_resources(self, username, password, status, **kwargs)
def cf_manager_rest_api_get_resources_of_sled_status_with_http_info(self, username, password, sled_ip, **kwargs)
def cf_manager_rest_api_post_resources_with_http_info(self, username, password, **kwargs)
def cf_manager_rest_api_put_resources_of_sled_status(self, username, password, sled_ip, new_status, **kwargs)
def cf_manager_rest_api_get_single_resource_status(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_put_resources_of_sled_status_in_state_with_http_info(self, username, password, sled_ip, status, new_status, **kwargs)
def cf_manager_rest_api_put_resource_status(self, username, password, resource_id, new_status, **kwargs)
def cf_manager_rest_api_get_single_resource(self, username, password, resource_id, **kwargs)
def __init__(self, api_client=None)
def cf_manager_rest_api_get_resources_with_http_info(self, username, password, **kwargs)
def cf_manager_rest_api_get_single_resource_with_http_info(self, username, password, resource_id, **kwargs)
def cf_manager_rest_api_post_resources(self, username, password, **kwargs)
def cf_manager_rest_api_put_resource_status_with_http_info(self, username, password, resource_id, new_status, **kwargs)
def cf_manager_rest_api_put_resources_of_sled_status_with_http_info(self, username, password, sled_ip, new_status, **kwargs)